[gnutls] - more patching for internal errors regression (#629858) patch by Vivek Dasmohapatra

Tomáš Mráz tmraz at fedoraproject.org
Thu Sep 23 16:35:45 UTC 2010


commit 599424428893d7e36dca16b57c272d299447b05c
Author: Tomas Mraz <tmraz at fedoraproject.org>
Date:   Thu Sep 23 18:35:42 2010 +0200

    - more patching for internal errors regression (#629858)
      patch by Vivek Dasmohapatra

 gnutls-2.10.1-imed-ret.patch |   28 ++++++++++++++++++++++++++++
 gnutls.spec                  |    8 +++++++-
 2 files changed, 35 insertions(+), 1 deletions(-)
---
diff --git a/gnutls-2.10.1-imed-ret.patch b/gnutls-2.10.1-imed-ret.patch
new file mode 100644
index 0000000..a8bec59
--- /dev/null
+++ b/gnutls-2.10.1-imed-ret.patch
@@ -0,0 +1,28 @@
+From e6cc32d6af7749826807badd258224ec1bfa31ae Mon Sep 17 00:00:00 2001
+From: Vivek Dasmohapatra <vivek at collabora.co.uk>
+Date: Thu, 23 Sep 2010 16:43:12 +0100
+Subject: [PATCH] IMED_RET macro should not clear session hash data if we are returning EAGAIN
+
+GNUTLS_E_AGAIN implies we haven't finished the operation in question,
+and therefore should not be clearing the cached hash data.
+---
+ lib/gnutls_handshake.c |    3 ++-
+ 1 files changed, 2 insertions(+), 1 deletions(-)
+
+diff --git a/lib/gnutls_handshake.c b/lib/gnutls_handshake.c
+index 84e6773..6e397b2 100644
+--- a/lib/gnutls_handshake.c
++++ b/lib/gnutls_handshake.c
+@@ -2736,7 +2736,8 @@ gnutls_handshake (gnutls_session_t session)
+ 		if (check_fatal != 0 && gnutls_error_is_fatal(ret)==0) return ret; \
+ 		gnutls_assert(); \
+ 		ERR( str, ret); \
+-		_gnutls_handshake_hash_buffers_clear(session); \
++                if (ret != GNUTLS_E_AGAIN) \
++		        _gnutls_handshake_hash_buffers_clear(session); \
+ 		return ret; \
+ 	} } while (0)
+ 
+-- 
+1.7.0
+
diff --git a/gnutls.spec b/gnutls.spec
index 7e23fdc..cc2c753 100644
--- a/gnutls.spec
+++ b/gnutls.spec
@@ -1,7 +1,7 @@
 Summary: A TLS protocol implementation
 Name: gnutls
 Version: 2.10.1
-Release: 2%{?dist}
+Release: 3%{?dist}
 # The libgnutls library is LGPLv2+, utilities and remaining libraries are GPLv3+
 License: GPLv3+ and LGPLv2+
 Group: System Environment/Libraries
@@ -21,6 +21,7 @@ Patch2: gnutls-2.8.6-link-libgcrypt.patch
 Patch3: gnutls-2.10.1-nosrp.patch
 # Backport from upstream git
 Patch4: gnutls-2.10.1-handshake-errors.patch
+Patch5: gnutls-2.10.1-imed-ret.patch
 
 BuildRoot:  %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 Requires: libgcrypt >= 1.2.2
@@ -77,6 +78,7 @@ This package contains Guile bindings for the library.
 %patch2 -p1 -b .link
 %patch3 -p1 -b .nosrp
 %patch4 -p1 -b .errors
+%patch5 -p1 -b .imed-ret
 
 for i in auth_srp_rsa.c auth_srp_sb64.c auth_srp_passwd.c auth_srp.c gnutls_srp.c ext_srp.c; do
     touch lib/$i
@@ -160,6 +162,10 @@ fi
 %{_datadir}/guile/site/gnutls.scm
 
 %changelog
+* Thu Sep 23 2010 Tomas Mraz <tmraz at redhat.com> 2.10.1-3
+- more patching for internal errors regression (#629858)
+  patch by Vivek Dasmohapatra
+
 * Tue Sep 21 2010 Tomas Mraz <tmraz at redhat.com> 2.10.1-2
 - backported patch from upstream git hopefully fixing internal errors
   (#629858)


More information about the scm-commits mailing list