[arch-commits] Commit in curl/trunk (2 files)

Jan Steffens heftig at archlinux.org
Tue Feb 19 15:10:35 UTC 2019


    Date: Tuesday, February 19, 2019 @ 15:10:34
  Author: heftig
Revision: 346556

7.64.0-9: FS#61688

Added:
  curl/trunk/0001-singlesocket-fix-the-sincebefore-placement.patch
Modified:
  curl/trunk/PKGBUILD

-------------------------------------------------------+
 0001-singlesocket-fix-the-sincebefore-placement.patch |   52 ++++++++++++++++
 PKGBUILD                                              |    9 ++
 2 files changed, 59 insertions(+), 2 deletions(-)

Added: 0001-singlesocket-fix-the-sincebefore-placement.patch
===================================================================
--- 0001-singlesocket-fix-the-sincebefore-placement.patch	                        (rev 0)
+++ 0001-singlesocket-fix-the-sincebefore-placement.patch	2019-02-19 15:10:34 UTC (rev 346556)
@@ -0,0 +1,52 @@
+From b7753be57d7bdb6b909f1a0a4207950e18100d79 Mon Sep 17 00:00:00 2001
+Message-Id: <b7753be57d7bdb6b909f1a0a4207950e18100d79.1550588688.git.jan.steffens at gmail.com>
+From: Daniel Stenberg <daniel at haxx.se>
+Date: Tue, 19 Feb 2019 15:56:54 +0100
+Subject: [PATCH] singlesocket: fix the 'sincebefore' placement
+
+The variable wasn't properly reset within the loop and thus could remain
+set for sockets that hadn't been set before and thus missed notifying
+the app.
+
+Detected-by: Jan Alexander Steffens
+Fixes #3585
+---
+ lib/multi.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/multi.c b/lib/multi.c
+index aaae8b978..521262b2b 100644
+--- a/lib/multi.c
++++ b/lib/multi.c
+@@ -2349,26 +2349,26 @@ static CURLMcode singlesocket(struct Curl_multi *multi,
+   int num;
+   unsigned int curraction;
+   int actions[MAX_SOCKSPEREASYHANDLE];
+-  unsigned int comboaction;
+-  bool sincebefore = FALSE;
+ 
+   for(i = 0; i< MAX_SOCKSPEREASYHANDLE; i++)
+     socks[i] = CURL_SOCKET_BAD;
+ 
+   /* Fill in the 'current' struct with the state as it is now: what sockets to
+      supervise and for what actions */
+   curraction = multi_getsock(data, socks, MAX_SOCKSPEREASYHANDLE);
+ 
+   /* We have 0 .. N sockets already and we get to know about the 0 .. M
+      sockets we should have from now on. Detect the differences, remove no
+      longer supervised ones and add new ones */
+ 
+   /* walk over the sockets we got right now */
+   for(i = 0; (i< MAX_SOCKSPEREASYHANDLE) &&
+         (curraction & (GETSOCK_READSOCK(i) | GETSOCK_WRITESOCK(i)));
+       i++) {
+     unsigned int action = CURL_POLL_NONE;
+     unsigned int prevaction = 0;
++    unsigned int comboaction;
++    bool sincebefore = FALSE;
+ 
+     s = socks[i];
+ 
+-- 
+2.20.1
+

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2019-02-19 13:54:50 UTC (rev 346555)
+++ PKGBUILD	2019-02-19 15:10:34 UTC (rev 346556)
@@ -6,7 +6,7 @@
 
 pkgname=curl
 pkgver=7.64.0
-pkgrel=8
+pkgrel=9
 pkgdesc="An URL retrieval utility and library"
 arch=('x86_64')
 url="https://curl.haxx.se"
@@ -17,11 +17,13 @@
 source=("https://curl.haxx.se/download/$pkgname-$pkgver.tar.gz"{,.asc}
         "0001-connection_check-set-data-to-the-transfer-doing-the-.patch"
         "0001-connection_check-restore-original-conn-data-after-th.patch"
+        "0001-singlesocket-fix-the-sincebefore-placement.patch"
         "0001-multi-remove-verbose-Expire-in-messages.patch")
 sha512sums=('ea0e68f9cbf2eb4f235d8506962dcc7709f769ef3526c0e4c130fdaf7186a1a13b303c6ce919cb9125bbf7c64ddf4f8efb3d9269b906f856e6d7b3def027fb81'
             'SKIP'
             'e9fdd70ec6798f48080582e4cb554fc4cd247075c293c66dcf8b27cab151def1c709c306e4dc8a1439b9843f31fe51248b5d6c7f5183e4af65819a084fddcb1f'
             'adcbf6309e5d69ede876966790dd504da3097a9e03fedf77d44e10fddcb24a5eaa29b4c9229c813d54bd0c2141211e46b50ca58d89608f7c391434e469316cbd'
+            '17c8c19e874bfed0736d579300be5a94f87467d1a2c346fe4dca1698fb73c05d02639cf712c95125f32bbd869457d60be4a1ca0f3d5cbc8b091bb35eb2594b15'
             'f09b63c36bd958c35bf6e3885efe46fea75fa2780510cac66220bfc1d771de9040560586e0672dac5eb7db7acf67051cf74e56518a8ada6f691c6d8f9dc84fa4')
 validpgpkeys=('27EDEAF22F3ABCEB50DB9A125CC908FDB71E12C2') # Daniel Stenberg
 
@@ -34,6 +36,9 @@
   # https://github.com/curl/curl/issues/3541
   patch -Np1 < ../0001-connection_check-set-data-to-the-transfer-doing-the-.patch
   patch -Np1 < ../0001-connection_check-restore-original-conn-data-after-th.patch
+
+  # https://bugs.archlinux.org/task/61688
+  patch -Np1 < ../0001-singlesocket-fix-the-sincebefore-placement.patch
 }
 
 build() {
@@ -63,5 +68,5 @@
   make DESTDIR="$pkgdir" install -C scripts
 
   # license
-  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
+  install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 COPYING
 }



More information about the arch-commits mailing list