[SCM] qtbase packaging branch, experimental, updated. debian/5.4.1+dfsg-2-19-gb052c99

Lisandro Damián Nicanor Pérez lisandro at moszumanska.debian.org
Wed May 13 15:43:04 UTC 2015


Gitweb-URL: http://git.debian.org/?p=pkg-kde/qt/qtbase.git;a=commitdiff;h=b052c99

The following commit has been merged in the experimental branch:
commit b052c99ab068b5c7adeb5b7c79220c8a31e3f05e
Author: Lisandro Damián Nicanor Pérez Meyer <perezmeyer at gmail.com>
Date:   Wed May 13 12:37:34 2015 -0300

    Backport tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch
---
 debian/changelog                                   |  2 +
 debian/patches/series                              |  1 +
 ...rkDiskCache-Stop-using-actual-web-servers.patch | 63 ++++++++++++++++++++++
 3 files changed, 66 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index eb8a4d3..b5428d3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -29,6 +29,8 @@ qtbase-opensource-src (5.4.1+dfsg-3) UNRELEASED; urgency=medium
     (Closes: #783134):
     - fixes_crash_in_bmp_and_ico_image_decoders.patch
     - fixes_crash_in_gif_image_decoder.patch
+  * Backport tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch to solve
+    tests wanting to access network services (Closes: #785207).
 
  -- Debian Qt/KDE Maintainers <debian-qt-kde at lists.debian.org>  Thu, 05 Mar 2015 10:26:29 +0300
 
diff --git a/debian/patches/series b/debian/patches/series
index 4b42677..b3bb713 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -9,6 +9,7 @@ require_fpic_instead_of_fpie.patch
 make_qglobal_h_complain_if_you_use_fpie.patch
 fixes_crash_in_bmp_and_ico_image_decoders.patch
 fixes_crash_in_gif_image_decoder.patch
+tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch
 
 # Debian specific.
 revert_upstream_bsymbolic_change.patch
diff --git a/debian/patches/tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch b/debian/patches/tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch
new file mode 100644
index 0000000..71e2c1b
--- /dev/null
+++ b/debian/patches/tst_QNetworkDiskCache-Stop-using-actual-web-servers.patch
@@ -0,0 +1,63 @@
+From: Thiago Macieira <thiago.macieira at intel.com>
+Date: Tue, 3 Mar 2015 16:31:52 -0800
+Subject: tst_QNetworkDiskCache: Stop using actual web servers
+
+www.example.com is a reserved domain (RFC 6761), but IANA is running a
+web server there. As for www.foo.com, that also exists, is a real
+website and is often content-filtered in corporations (it triggers a
+firewall warning for me -- "You attempted to visit a site that is in
+violation of Intel acceptable use guidelines").
+
+So use a localhost instead, since we don't actually need to connect to
+the servers to do the work. And since we don't need to connect, I chose
+port 4 as it's extremely unlikely someone is running an HTTP server
+there (/etc/services lists it as unassigned).
+
+Change-Id: Ia0aac2f09e9245339951ffff13c82439c6d5f945
+Reviewed-by: Lars Knoll <lars.knoll at digia.com>
+Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen at theqtcompany.com>
+Origin: upstream, 5.5.0, commit:96e9b41e254aaeff2e1bb320791fa6e19f179e2b
+---
+ .../network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp    | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp b/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
+index a2f1668..8eee4bd 100644
+--- a/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
++++ b/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
+@@ -38,7 +38,7 @@
+ 
+ #include <algorithm>
+ 
+-#define EXAMPLE_URL "http://user:pass@www.example.com/#foo"
++#define EXAMPLE_URL "http://user:pass@localhost:4/#foo"
+ //cached objects are organized into these many subdirs
+ #define NUM_SUBDIRECTORIES 16
+ 
+@@ -409,7 +409,7 @@ void tst_QNetworkDiskCache::accessAfterRemoveReadyReadSlot()
+ void tst_QNetworkDiskCache::setCookieHeader() // QTBUG-41514
+ {
+     SubQNetworkDiskCache *cache = new SubQNetworkDiskCache();
+-    url = QUrl("http://www.foo.com/cookieTest.html");
++    url = QUrl("http://localhost:4/cookieTest.html");   // hopefully no one is running an HTTP server on port 4
+     QNetworkCacheMetaData metaData;
+     metaData.setUrl(url);
+ 
+@@ -518,7 +518,7 @@ void tst_QNetworkDiskCache::expire()
+         if (i % 3 == 0)
+             QTest::qWait(2000);
+         QNetworkCacheMetaData m;
+-        m.setUrl(QUrl("http://www.foo.com/" + QString::number(i)));
++        m.setUrl(QUrl("http://localhost:4/" + QString::number(i)));
+         QIODevice *d = cache.prepare(m);
+         QString bigString;
+         bigString.fill(QLatin1Char('Z'), (1024 * 1024 / 4));
+@@ -540,7 +540,7 @@ void tst_QNetworkDiskCache::expire()
+     std::sort(cacheList.begin(), cacheList.end());
+     for (int i = 0; i < cacheList.count(); ++i) {
+         QString fileName = cacheList[i];
+-        QCOMPARE(fileName, QString("http://www.foo.com/%1").arg(i + 6));
++        QCOMPARE(fileName, QString("http://localhost:4/%1").arg(i + 6));
+     }
+ }
+ 

-- 
qtbase packaging



More information about the pkg-kde-commits mailing list