[packages/qt4] - missing patch

arekm arekm at pld-linux.org
Sun Nov 6 22:50:50 CET 2016


commit 0b0e37094ca6e38d195e7134e7e69617a646b95a
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Sun Nov 6 22:50:43 2016 +0100

    - missing patch

 no_libicu_message.diff              | 30 +++++++++++++++++++
 xmlpatterns_stack_overflow_fix.diff | 60 +++++++++++++++++++++++++++++++++++++
 2 files changed, 90 insertions(+)
---
diff --git a/no_libicu_message.diff b/no_libicu_message.diff
new file mode 100644
index 0000000..db3f63c
--- /dev/null
+++ b/no_libicu_message.diff
@@ -0,0 +1,30 @@
+Author: Pino Toscano <pino at debian.org>
+Description: Disable the warnings about not being able to dlopen ICU libraries.
+ Most of the applications don't need ICU-based functions for locale-aware
+ string upper- and lower-casing and comparison. If not present, Qt will use the
+ own ways (i.e. those used also in Qt < 4.8).
+Last-Update: 2012-05-21
+Forwarded: not-needed
+
+--- a/src/corelib/tools/qlocale_icu.cpp
++++ b/src/corelib/tools/qlocale_icu.cpp
+@@ -88,7 +88,9 @@ bool qt_initIcu(const QString &localeStr
+         QLibrary lib(QLatin1String("icui18n"), QLatin1String(U_ICU_VERSION_SHORT));
+         lib.setLoadHints(QLibrary::ImprovedSearchHeuristics);
+         if (!lib.load()) {
++#if 0
+             qWarning() << "Unable to load library icui18n" << lib.errorString();
++#endif
+             status = ErrorLoading;
+             return false;
+         }
+@@ -118,7 +120,9 @@ bool qt_initIcu(const QString &localeStr
+         QLibrary ucLib(QLatin1String("icuuc"), QLatin1String(U_ICU_VERSION_SHORT));
+         ucLib.setLoadHints(QLibrary::ImprovedSearchHeuristics);
+         if (!ucLib.load()) {
++#if 0
+             qWarning() << "Unable to load library icuuc" << ucLib.errorString();
++#endif
+             status = ErrorLoading;
+             return false;
+         }
diff --git a/xmlpatterns_stack_overflow_fix.diff b/xmlpatterns_stack_overflow_fix.diff
new file mode 100644
index 0000000..daf1ee7
--- /dev/null
+++ b/xmlpatterns_stack_overflow_fix.diff
@@ -0,0 +1,60 @@
+commit d1b17740ed4d9b1e3c3ad5898bb8259969dc77df
+Author: Kamil Rojewski <kamil.rojewski at gmail.com>
+Date:   Wed Aug 13 10:38:38 2014 +0200
+
+    fix for stack overflow
+    
+    Recursion in item mapping iterator caused a stack
+    overflow for large datasets.
+    
+    Task-number: QTBUG-40153
+    Change-Id: I693798de0ecfd3a920a3dd270172ce7ec3c13d8d
+    Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki at digia.com>
+
+Index: qt4-x11/src/xmlpatterns/iterators/qitemmappingiterator_p.h
+===================================================================
+--- qt4-x11.orig/src/xmlpatterns/iterators/qitemmappingiterator_p.h	2014-09-04 11:47:43.979391542 -0500
++++ qt4-x11/src/xmlpatterns/iterators/qitemmappingiterator_p.h	2014-09-04 11:47:43.975391542 -0500
+@@ -117,24 +117,28 @@
+          */
+         virtual TResult next()
+         {
+-            const TSource sourceItem(m_it->next());
+-
+-            if(qIsForwardIteratorEnd(sourceItem))
++            while (true)
+             {
+-                m_current = TResult();
+-                m_position = -1;
+-                return TResult();
+-            }
+-            else
+-            {
+-                m_current = m_mapper->mapToItem(sourceItem, m_context);
+-                if(qIsForwardIteratorEnd(m_current))
+-                    return next(); /* The mapper returned null, so continue with the next in the source. */
+-                else
++                const TSource &sourceItem = m_it->next();
++                if (qIsForwardIteratorEnd(sourceItem))
+                 {
+-                    ++m_position;
++                    m_current = TResult();
++                    m_position = -1;
+                     return m_current;
+                 }
++                else
++                {
++                    m_current = m_mapper->mapToItem(sourceItem, m_context);
++                    if (qIsForwardIteratorEnd(m_current))
++                    {
++                        continue; /* The mapper returned null, so continue with the next in the source. */
++                    }
++                    else
++                    {
++                        ++m_position;
++                        return m_current;
++                    }
++                }
+             }
+         }
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/qt4.git/commitdiff/0b0e37094ca6e38d195e7134e7e69617a646b95a



More information about the pld-cvs-commit mailing list