[glib-networking] gnutls: Avoid assertion in finish_handshake()
- From: Stefan Walter <stefw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib-networking] gnutls: Avoid assertion in finish_handshake()
- Date: Thu, 29 Nov 2012 21:58:38 +0000 (UTC)
commit 8eb8d56f02a2e4c9adebe45200f72a05a96a0e5b
Author: Stef Walter <stefw gnome org>
Date: Thu Nov 29 14:15:09 2012 +0100
gnutls: Avoid assertion in finish_handshake()
https://bugzilla.gnome.org/show_bug.cgi?id=689274
tls/gnutls/gtlsconnection-gnutls.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/tls/gnutls/gtlsconnection-gnutls.c b/tls/gnutls/gtlsconnection-gnutls.c
index b03ecb9..1cda0d2 100644
--- a/tls/gnutls/gtlsconnection-gnutls.c
+++ b/tls/gnutls/gtlsconnection-gnutls.c
@@ -539,18 +539,20 @@ claim_op (GTlsConnectionGnutls *gnutls,
if (gnutls->priv->need_finish_handshake)
{
+ GError *my_error = NULL;
gboolean success;
gnutls->priv->need_finish_handshake = FALSE;
g_mutex_unlock (&gnutls->priv->op_mutex);
- success = finish_handshake (gnutls, gnutls->priv->implicit_handshake, error);
+ success = finish_handshake (gnutls, gnutls->priv->implicit_handshake, &my_error);
g_clear_object (&gnutls->priv->implicit_handshake);
g_mutex_lock (&gnutls->priv->op_mutex);
gnutls->priv->handshaking = FALSE;
- if (!success || g_cancellable_set_error_if_cancelled (cancellable, error))
+ if (!success || g_cancellable_set_error_if_cancelled (cancellable, &my_error))
{
+ g_propagate_error (error, my_error);
g_mutex_unlock (&gnutls->priv->op_mutex);
return FALSE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]