xbps: merge patch from master to fix fallout of TLS SNI.

This commit is contained in:
Juan RP 2014-06-28 12:15:10 +02:00
parent 3b82e29e5c
commit 89571af784
2 changed files with 31 additions and 1 deletions

View File

@ -0,0 +1,30 @@
From 7bb36ddaa25e17df3ab3b6bf3454f1e7957d444d Mon Sep 17 00:00:00 2001
From: Juan RP <xtraeme@gmail.com>
Date: Sat, 28 Jun 2014 12:12:03 +0200
Subject: [PATCH] libfetch: fetch_close: make sure conn->ssl is valid before
shutting down.
---
lib/fetch/common.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/lib/fetch/common.c b/lib/fetch/common.c
index 5b03348..7764b27 100644
--- lib/fetch/common.c
+++ lib/fetch/common.c
@@ -732,8 +732,10 @@ fetch_close(conn_t *conn)
int ret;
#ifdef WITH_SSL
- SSL_shutdown(conn->ssl);
- SSL_free(conn->ssl);
+ if (conn->ssl) {
+ SSL_shutdown(conn->ssl);
+ SSL_free(conn->ssl);
+ }
#endif
ret = close(conn->sd);
if (conn->cache_url)
--
2.0.1

View File

@ -1,7 +1,7 @@
# Template file for 'xbps'
pkgname=xbps
version=0.37
revision=2
revision=3
bootstrap=yes
short_desc="The XBPS package system utilities"
maintainer="Juan RP <xtraeme@gmail.com>"