new upstream release - 7.64.1

This commit is contained in:
Kamil Dudka 2019-03-27 10:33:41 +01:00
parent 0ed971f14f
commit bbad3e0a62
12 changed files with 34 additions and 473 deletions

View File

@ -1,76 +0,0 @@
From 082034e2334b2d0795b2b324ff3e0635bb7d2b86 Mon Sep 17 00:00:00 2001
From: Alessandro Ghedini <alessandro@ghedini.me>
Date: Tue, 5 Feb 2019 20:44:14 +0000
Subject: [PATCH 1/2] zsh.pl: update regex to better match curl -h output
The current regex fails to match '<...>' arguments properly (e.g. those
with spaces in them), which causes an completion script with wrong
descriptions for some options.
The problem can be reproduced as follows:
% curl --reso<TAB>
Upstream-commit: dbd32f3241b297b96ee11a51da1a661f528ca026
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
scripts/zsh.pl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/zsh.pl b/scripts/zsh.pl
index 1257190..941b322 100755
--- a/scripts/zsh.pl
+++ b/scripts/zsh.pl
@@ -7,7 +7,7 @@ use warnings;
my $curl = $ARGV[0] || 'curl';
-my $regex = '\s+(?:(-[^\s]+),\s)?(--[^\s]+)\s([^\s.]+)?\s+(.*)';
+my $regex = '\s+(?:(-[^\s]+),\s)?(--[^\s]+)\s*(\<.+?\>)?\s+(.*)';
my @opts = parse_main_opts('--help', $regex);
my $opts_str;
--
2.17.2
From 45abc785e101346f19599aa5f9fa1617e525ec4d Mon Sep 17 00:00:00 2001
From: Alessandro Ghedini <alessandro@ghedini.me>
Date: Tue, 5 Feb 2019 21:06:26 +0000
Subject: [PATCH 2/2] zsh.pl: escape ':' character
':' is interpreted as separator by zsh, so if used as part of the argument
or option's description it needs to be escaped.
The problem can be reproduced as follows:
% curl -E <TAB>
Bug: https://bugs.debian.org/921452
Upstream-commit: b3cc8017b7364f588365be2b2629c49c142efdb7
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
scripts/zsh.pl | 3 +++
1 file changed, 3 insertions(+)
diff --git a/scripts/zsh.pl b/scripts/zsh.pl
index 941b322..0f9cbec 100755
--- a/scripts/zsh.pl
+++ b/scripts/zsh.pl
@@ -45,9 +45,12 @@ sub parse_main_opts {
my $option = '';
+ $arg =~ s/\:/\\\:/g if defined $arg;
+
$desc =~ s/'/'\\''/g if defined $desc;
$desc =~ s/\[/\\\[/g if defined $desc;
$desc =~ s/\]/\\\]/g if defined $desc;
+ $desc =~ s/\:/\\\:/g if defined $desc;
$option .= '{' . trim($short) . ',' if defined $short;
$option .= trim($long) if defined $long;
--
2.17.2

View File

@ -1,162 +0,0 @@
From 377101f138873bfa481785cb7d04c326006f0b5d Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Mon, 11 Feb 2019 07:56:00 +0100
Subject: [PATCH 1/3] connection_check: set ->data to the transfer doing the
check
The http2 code for connection checking needs a transfer to use. Make
sure a working one is set before handler->connection_check() is called.
Reported-by: jnbr on github
Fixes #3541
Closes #3547
Upstream-commit: 38d8e1bd4ed1ae52930ae466ecbac78e888b142f
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/url.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/url.c b/lib/url.c
index d5a9820..229c655 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -965,6 +965,7 @@ static bool extract_if_dead(struct connectdata *conn,
/* The protocol has a special method for checking the state of the
connection. Use it to check if the connection is dead. */
unsigned int state;
+ conn->data = data; /* use this transfer for now */
state = conn->handler->connection_check(conn, CONNCHECK_ISDEAD);
dead = (state & CONNRESULT_DEAD);
}
--
2.17.2
From 287f5d70395b3833f8901a57b29a48b87d84a9fe Mon Sep 17 00:00:00 2001
From: Jay Satiro <raysatiro@yahoo.com>
Date: Mon, 11 Feb 2019 23:00:00 -0500
Subject: [PATCH 2/3] connection_check: restore original conn->data after the
check
- Save the original conn->data before it's changed to the specified
data transfer for the connection check and then restore it afterwards.
This is a follow-up to 38d8e1b 2019-02-11.
History:
It was discovered a month ago that before checking whether to extract a
dead connection that that connection should be associated with a "live"
transfer for the check (ie original conn->data ignored and set to the
passed in data). A fix was landed in 54b201b which did that and also
cleared conn->data after the check. The original conn->data was not
restored, so presumably it was thought that a valid conn->data was no
longer needed.
Several days later it was discovered that a valid conn->data was needed
after the check and follow-up fix was landed in bbae24c which partially
reverted the original fix and attempted to limit the scope of when
conn->data was changed to only when pruning dead connections. In that
case conn->data was not cleared and the original conn->data not
restored.
A month later it was discovered that the original fix was somewhat
correct; a "live" transfer is needed for the check in all cases
because original conn->data could be null which could cause a bad deref
at arbitrary points in the check. A fix was landed in 38d8e1b which
expanded the scope to all cases. conn->data was not cleared and the
original conn->data not restored.
A day later it was discovered that not restoring the original conn->data
may lead to busy loops in applications that use the event interface, and
given this observation it's a pretty safe assumption that there is some
code path that still needs the original conn->data. This commit is the
follow-up fix for that, it restores the original conn->data after the
connection check.
Assisted-by: tholin@users.noreply.github.com
Reported-by: tholin@users.noreply.github.com
Fixes https://github.com/curl/curl/issues/3542
Closes #3559
Upstream-commit: 4015fae044ce52a639c9358e22a9e948f287c89f
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/url.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/url.c b/lib/url.c
index 229c655..a77e92d 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -965,8 +965,10 @@ static bool extract_if_dead(struct connectdata *conn,
/* The protocol has a special method for checking the state of the
connection. Use it to check if the connection is dead. */
unsigned int state;
+ struct Curl_easy *olddata = conn->data;
conn->data = data; /* use this transfer for now */
state = conn->handler->connection_check(conn, CONNCHECK_ISDEAD);
+ conn->data = olddata;
dead = (state & CONNRESULT_DEAD);
}
else {
@@ -995,7 +997,6 @@ struct prunedead {
static int call_extract_if_dead(struct connectdata *conn, void *param)
{
struct prunedead *p = (struct prunedead *)param;
- conn->data = p->data; /* transfer to use for this check */
if(extract_if_dead(conn, p->data)) {
/* stop the iteration here, pass back the connection that was extracted */
p->extracted = conn;
--
2.17.2
From 15e3f2eef87bff1210f43921cb15f03c68be59f7 Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Tue, 19 Feb 2019 15:56:54 +0100
Subject: [PATCH 3/3] 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 miss notifying the app.
This is a follow-up to 4c35574 (shipped in curl 7.64.0)
Reported-by: buzo-ffm on github
Detected-by: Jan Alexander Steffens
Fixes #3585
Closes #3589
Upstream-commit: afc00e047c773faeaa60a5f86a246cbbeeba5819
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/multi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/multi.c b/lib/multi.c
index 130226f..28f4c47 100644
--- a/lib/multi.c
+++ b/lib/multi.c
@@ -2360,8 +2360,6 @@ 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;
@@ -2380,6 +2378,8 @@ static CURLMcode singlesocket(struct Curl_multi *multi,
i++) {
unsigned int action = CURL_POLL_NONE;
unsigned int prevaction = 0;
+ unsigned int comboaction;
+ bool sincebefore = FALSE;
s = socks[i];
--
2.17.2

View File

@ -1,42 +0,0 @@
From d73dc8d3e70bde0ef999ecf7bcd5585b9892371c Mon Sep 17 00:00:00 2001
From: Michael Wallner <mike@php.net>
Date: Mon, 25 Feb 2019 19:05:02 +0100
Subject: [PATCH] cookies: fix NULL dereference if flushing cookies with no
CookieInfo set
Regression brought by a52e46f3900fb0 (shipped in 7.63.0)
Closes #3613
Upstream-commit: 8eddb8f4259193633cfc95a42603958a89b31de5
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/cookie.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/cookie.c b/lib/cookie.c
index 4fb992a..d535170 100644
--- a/lib/cookie.c
+++ b/lib/cookie.c
@@ -1504,7 +1504,8 @@ static int cookie_output(struct CookieInfo *c, const char *dumphere)
struct Cookie **array;
/* at first, remove expired cookies */
- remove_expired(c);
+ if(c)
+ remove_expired(c);
if(!strcmp("-", dumphere)) {
/* use stdout */
@@ -1523,7 +1524,7 @@ static int cookie_output(struct CookieInfo *c, const char *dumphere)
"# This file was generated by libcurl! Edit at your own risk.\n\n",
out);
- if(c->numcookies) {
+ if(c && c->numcookies) {
array = malloc(sizeof(struct Cookie *) * c->numcookies);
if(!array) {
if(!use_stdout)
--
2.17.2

View File

@ -1,118 +0,0 @@
From 5ddabe85b2e3e4fd08d06980719d71a2aed77a5b Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Thu, 28 Feb 2019 20:34:36 +0100
Subject: [PATCH] threaded-resolver: shutdown the resolver thread without error
message
When a transfer is done, the resolver thread will be brought down. That
could accidentally generate an error message in the error buffer even
though this is not an error situationand the transfer would still return
OK. An application that still reads the error buffer could find a
"Could not resolve host: [host name]" message there and get confused.
Reported-by: Michael Schmid
Fixes #3629
Closes #3630
Upstream-commit: 754ae103989a6ad0869d23a6a427d652b5b4a2fe
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/asyn-thread.c | 68 ++++++++++++++++++++++++++---------------------
1 file changed, 38 insertions(+), 30 deletions(-)
diff --git a/lib/asyn-thread.c b/lib/asyn-thread.c
index a9679d0..55e0811 100644
--- a/lib/asyn-thread.c
+++ b/lib/asyn-thread.c
@@ -461,6 +461,42 @@ static CURLcode resolver_error(struct connectdata *conn)
return result;
}
+static CURLcode thread_wait_resolv(struct connectdata *conn,
+ struct Curl_dns_entry **entry,
+ bool report)
+{
+ struct thread_data *td = (struct thread_data*) conn->async.os_specific;
+ CURLcode result = CURLE_OK;
+
+ DEBUGASSERT(conn && td);
+ DEBUGASSERT(td->thread_hnd != curl_thread_t_null);
+
+ /* wait for the thread to resolve the name */
+ if(Curl_thread_join(&td->thread_hnd)) {
+ if(entry)
+ result = getaddrinfo_complete(conn);
+ }
+ else
+ DEBUGASSERT(0);
+
+ conn->async.done = TRUE;
+
+ if(entry)
+ *entry = conn->async.dns;
+
+ if(!conn->async.dns && report)
+ /* a name was not resolved, report error */
+ result = resolver_error(conn);
+
+ destroy_async_data(&conn->async);
+
+ if(!conn->async.dns && report)
+ connclose(conn, "asynch resolve failed");
+
+ return result;
+}
+
+
/*
* Until we gain a way to signal the resolver threads to stop early, we must
* simply wait for them and ignore their results.
@@ -473,7 +509,7 @@ void Curl_resolver_kill(struct connectdata *conn)
unfortunately. Otherwise, we can simply cancel to clean up any resolver
data. */
if(td && td->thread_hnd != curl_thread_t_null)
- (void)Curl_resolver_wait_resolv(conn, NULL);
+ (void)thread_wait_resolv(conn, NULL, FALSE);
else
Curl_resolver_cancel(conn);
}
@@ -494,35 +530,7 @@ void Curl_resolver_kill(struct connectdata *conn)
CURLcode Curl_resolver_wait_resolv(struct connectdata *conn,
struct Curl_dns_entry **entry)
{
- struct thread_data *td = (struct thread_data*) conn->async.os_specific;
- CURLcode result = CURLE_OK;
-
- DEBUGASSERT(conn && td);
- DEBUGASSERT(td->thread_hnd != curl_thread_t_null);
-
- /* wait for the thread to resolve the name */
- if(Curl_thread_join(&td->thread_hnd)) {
- if(entry)
- result = getaddrinfo_complete(conn);
- }
- else
- DEBUGASSERT(0);
-
- conn->async.done = TRUE;
-
- if(entry)
- *entry = conn->async.dns;
-
- if(!conn->async.dns)
- /* a name was not resolved, report error */
- result = resolver_error(conn);
-
- destroy_async_data(&conn->async);
-
- if(!conn->async.dns)
- connclose(conn, "asynch resolve failed");
-
- return result;
+ return thread_wait_resolv(conn, entry, TRUE);
}
/*
--
2.17.2

View File

@ -1,32 +0,0 @@
From 2e8f4d01cdd07779e0582257cb6b53c5a91d6504 Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Mon, 11 Feb 2019 22:57:33 +0100
Subject: [PATCH] multi: remove verbose "Expire in" ... messages
Reported-by: James Brown
Bug: https://curl.haxx.se/mail/archive-2019-02/0013.html
Closes #3558
Upstream-commit: aabc7ae5ecf70973add429b5acbc86d6a57e4da5
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
---
lib/multi.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/lib/multi.c b/lib/multi.c
index 28f4c47..856cc22 100644
--- a/lib/multi.c
+++ b/lib/multi.c
@@ -3028,9 +3028,6 @@ void Curl_expire(struct Curl_easy *data, time_t milli, expire_id id)
DEBUGASSERT(id < EXPIRE_LAST);
- infof(data, "Expire in %ld ms for %x (transfer %p)\n",
- (long)milli, id, data);
-
set = Curl_now();
set.tv_sec += milli/1000;
set.tv_usec += (unsigned int)(milli%1000)*1000;
--
2.17.2

View File

@ -12,7 +12,7 @@ diff --git a/configure b/configure
index 8f079a3..53b4774 100755
--- a/configure
+++ b/configure
@@ -16250,18 +16250,11 @@ $as_echo "yes" >&6; }
@@ -16273,18 +16273,11 @@ $as_echo "yes" >&6; }
gccvhi=`echo $gccver | cut -d . -f1`
gccvlo=`echo $gccver | cut -d . -f2`
compiler_num=`(expr $gccvhi "*" 100 + $gccvlo) 2>/dev/null`

View File

@ -14,8 +14,8 @@ index e441278..b0958b6 100644
+-g "http://%HOST6IP:%HTTP6PORT/1083" --interface localhost6
</command>
<precheck>
-perl -e "if ('%CLIENT6IP' ne '[::1]') {print 'Test requires default test server host address';} else {exec './server/resolve --ipv6 ip6-localhost'; print 'Cannot run precheck resolve';}"
+perl -e "if ('%CLIENT6IP' ne '[::1]') {print 'Test requires default test server host address';} else {exec './server/resolve --ipv6 localhost6'; print 'Cannot run precheck resolve';}"
-perl -e "if ('%CLIENT6IP' ne '[::1]') {print 'Test requires default test client host address';} else {exec './server/resolve --ipv6 ip6-localhost'; print 'Cannot run precheck resolve';}"
+perl -e "if ('%CLIENT6IP' ne '[::1]') {print 'Test requires default test client host address';} else {exec './server/resolve --ipv6 localhost6'; print 'Cannot run precheck resolve';}"
</precheck>
</client>

View File

@ -26,7 +26,7 @@ diff --git a/tests/libtest/Makefile.inc b/tests/libtest/Makefile.inc
index 080421b..ea3b806 100644
--- a/tests/libtest/Makefile.inc
+++ b/tests/libtest/Makefile.inc
@@ -521,6 +521,7 @@ lib1558_SOURCES = lib1558.c $(SUPPORTFILES) $(TESTUTIL) $(WARNLESS)
@@ -530,6 +530,7 @@ lib1558_SOURCES = lib1558.c $(SUPPORTFILES) $(TESTUTIL) $(WARNLESS)
lib1558_LDADD = $(TESTUTIL_LIBS)
lib1560_SOURCES = lib1560.c $(SUPPORTFILES) $(TESTUTIL) $(WARNLESS)

View File

@ -1,11 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQEzBAABCgAdFiEEJ+3q8i86vOtQ25oSXMkI/bceEsIFAlxahccACgkQXMkI/bce
EsKdrAf+OoNH+Yz1HfJG5MtmEi2sgRC56iAvZBQujPG8SJYGnT3D2nLiuC2+bzA8
eMCqisodW5f6lV/9JRvLmLS0dhxAfdf/NHlMOdtgSv+NzVGsggpHeYEZ7HucRHsQ
AKZ6/wx7rby8yZqrn2s7yWWB0qgiajWx30r+CJEYXpuw+YwZ2qZo5ecM7fa/J9ko
ESwb7BLF6KMkdSz1wSApwCdznB/BXOaPrUBMiOcwO7ftq/t1ZmqnUWLtdlSp8OoH
Tw832H1kCP2OFHcOFTQmZJLagRQtLBhC522wNsagXaMwak6uhoFApcAPqoPdm4Pm
PvTO6aAopZk+sX9VemdSQzx/4ysT3w==
=HOlc
-----END PGP SIGNATURE-----

11
curl-7.64.1.tar.xz.asc Normal file
View File

@ -0,0 +1,11 @@
-----BEGIN PGP SIGNATURE-----
iQEzBAABCgAdFiEEJ+3q8i86vOtQ25oSXMkI/bceEsIFAlybHwMACgkQXMkI/bce
EsIlxQf+LUj/zeWzTgxXIFgtfba+RKb66RpWhgzKLBpiGFQjhckILFJ+Li625SE3
9fCrIslGuY2S4G6fRH1qEIZVglpA185sTeY241/JK788ftJFFQd2GtM/+Ysrla5h
zc2wD3amDXcROWI+QIl/dBy7xRnW8TSTMu2sEPLarsNtXK9EC+h/WIkeYW1amMf2
a8vRFwXFZ7OrEiq7A0avvmbrQVgIIGP/zyz44ZN00PPgLm40c1rngHGBJJzEMVSS
ClZ+wUQ+AyamL3Ls9a+V3SF3IuVrFInjv5Y1OshPULaqL2VxPsCVw67sCVouePMS
J0u3GZPsE+sVbx7cHCfZFdSnutFBKQ==
=WUio
-----END PGP SIGNATURE-----

View File

@ -1,25 +1,10 @@
Summary: A utility for getting files from remote servers (FTP, HTTP, and others)
Name: curl
Version: 7.64.0
Release: 6%{?dist}
Version: 7.64.1
Release: 1%{?dist}
License: MIT
Source: https://curl.haxx.se/download/%{name}-%{version}.tar.xz
# make zsh completion work again
Patch1: 0001-curl-7.64.0-zsh-completion.patch
# prevent NetworkManager from leaking file descriptors (#1680198)
Patch2: 0002-curl-7.64.0-nm-fd-leak.patch
# fix NULL dereference if flushing cookies with no CookieInfo set (#1683676)
Patch3: 0003-curl-7.64.0-cookie-segfault.patch
# avoid spurious "Could not resolve host: [host name]" error messages
Patch4: 0004-curl-7.64.0-spurious-resolver-error.patch
# remove verbose "Expire in" ... messages (#1690971)
Patch5: 0005-curl-7.64.0-expire-in-verbose-msgs.patch
# patch making libcurl multilib ready
Patch101: 0101-curl-7.32.0-multilib.patch
@ -181,11 +166,6 @@ be installed.
%setup -q
# upstream patches
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
# Fedora patches
%patch101 -p1
@ -312,6 +292,10 @@ make DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" install
LD_LIBRARY_PATH="$RPM_BUILD_ROOT%{_libdir}:$LD_LIBRARY_PATH" \
make DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" install -C scripts
# do not install /usr/share/fish/completions/curl.fish which is also installed
# by fish-3.0.2-1.module_f31+3716+57207597 and would trigger a conflict
rm -rf ${RPM_BUILD_ROOT}%{_datadir}/fish
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libcurl.la
%ldconfig_scriptlets -n libcurl
@ -319,13 +303,17 @@ rm -f ${RPM_BUILD_ROOT}%{_libdir}/libcurl.la
%ldconfig_scriptlets -n libcurl-minimal
%files
%doc CHANGES README*
%doc docs/BUGS docs/FAQ docs/FEATURES
%doc docs/MANUAL docs/RESOURCES
%doc docs/TheArtOfHttpScripting docs/TODO
%doc CHANGES
%doc README
%doc docs/BUGS
%doc docs/FAQ
%doc docs/FEATURES
%doc docs/RESOURCES
%doc docs/TODO
%doc docs/TheArtOfHttpScripting
%{_bindir}/curl
%{_mandir}/man1/curl.1*
%{_datadir}/zsh/site-functions
%{_datadir}/zsh
%files -n libcurl
%license COPYING
@ -353,6 +341,9 @@ rm -f ${RPM_BUILD_ROOT}%{_libdir}/libcurl.la
%{_libdir}/libcurl.so.4.[0-9].[0-9].minimal
%changelog
* Wed Mar 27 2019 Kamil Dudka <kdudka@redhat.com> - 7.64.1-1
- new upstream release
* Mon Mar 25 2019 Kamil Dudka <kdudka@redhat.com> - 7.64.0-6
- remove verbose "Expire in" ... messages (#1690971)

View File

@ -1 +1 @@
SHA512 (curl-7.64.0.tar.xz) = 953f1f5336ce5dfd1b9f933624432d401552d91ee02d39ecde6f023c956f99ec6aae8d7746d7c34b6eb2d6452f114e67da4e64d9c8dd90b7644b7844e7b9b423
SHA512 (curl-7.64.1.tar.xz) = 1629ba154691bf9d936e0bce69ec8fb54991a40d34bc16ffdfb117f91e3faa93164154fc9ae9043e963955862e69515018673b7239f2fd625684a59cdd1db81c