From b44b49d9ed4dddbf7df1a79548f57be462967c9c Mon Sep 17 00:00:00 2001 From: gdt Date: Fri, 20 Apr 2007 18:04:15 +0000 Subject: Add patch from maintainer to add global lock around SSL initialization. Resolves SMP crash, but it seems really openssl should be compiled with thread spport. --- mail/mail-notification/Makefile | 3 ++- mail/mail-notification/distinfo | 3 ++- mail/mail-notification/patches/patch-aa | 24 ++++++++++++++++++++++++ 3 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 mail/mail-notification/patches/patch-aa (limited to 'mail/mail-notification') diff --git a/mail/mail-notification/Makefile b/mail/mail-notification/Makefile index c1b19d653f2..87a7db91c5c 100644 --- a/mail/mail-notification/Makefile +++ b/mail/mail-notification/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.33 2007/04/20 14:29:21 gdt Exp $ +# $NetBSD: Makefile,v 1.34 2007/04/20 18:04:15 gdt Exp $ # DISTNAME= mail-notification-4.0 +PKGREVISION= 1 CATEGORIES= mail gnome MASTER_SITES= http://savannah.nongnu.org/download/mailnotify/ diff --git a/mail/mail-notification/distinfo b/mail/mail-notification/distinfo index e4e81809f47..ec231a5bdad 100644 --- a/mail/mail-notification/distinfo +++ b/mail/mail-notification/distinfo @@ -1,6 +1,7 @@ -$NetBSD: distinfo,v 1.8 2007/04/20 14:29:21 gdt Exp $ +$NetBSD: distinfo,v 1.9 2007/04/20 18:04:15 gdt Exp $ SHA1 (mail-notification-4.0.tar.gz) = 9cc832ff75913a80198e5b3d6a51c282e422a20f RMD160 (mail-notification-4.0.tar.gz) = 67804814f82a8048c5887dcf4e3c2d827790dc80 Size (mail-notification-4.0.tar.gz) = 956007 bytes +SHA1 (patch-aa) = a7e0c6d5115c41a30a29bf0579514f6fdb05e0c5 SHA1 (patch-af) = 29d4281671ef64d99e9367464137d50ebb9daee7 diff --git a/mail/mail-notification/patches/patch-aa b/mail/mail-notification/patches/patch-aa new file mode 100644 index 00000000000..cfa478ac847 --- /dev/null +++ b/mail/mail-notification/patches/patch-aa @@ -0,0 +1,24 @@ +--- src/mn-client-session.c.orig Wed Jan 17 15:07:49 2007 ++++ src/mn-client-session.c Fri Apr 20 19:05:51 2007 +@@ -369,6 +369,8 @@ + { + SSL_CTX *ctx; + GError *err = NULL; ++ static GStaticMutex ssl_lock = G_STATIC_MUTEX_INIT; ++ int status; + + g_return_val_if_fail(session != NULL, FALSE); + g_return_val_if_fail(session->ssl == NULL, FALSE); +@@ -394,7 +396,11 @@ + return FALSE; + } + +- if (SSL_connect(session->ssl) != 1) ++ g_static_mutex_lock(&ssl_lock); ++ status = SSL_connect(session->ssl); ++ g_static_mutex_unlock(&ssl_lock); ++ ++ if (status != 1) + { + mn_client_session_set_error(session, MN_CLIENT_SESSION_ERROR_OTHER, _("unable to perform the SSL/TLS handshake: %s"), mn_ssl_get_error()); + return FALSE; -- cgit v1.2.3