diff options
author | bsiegert <bsiegert@pkgsrc.org> | 2015-07-04 15:52:51 +0000 |
---|---|---|
committer | bsiegert <bsiegert@pkgsrc.org> | 2015-07-04 15:52:51 +0000 |
commit | f6ad535eda8f713b9bf859c2e275239e76c89483 (patch) | |
tree | 1fd02fbe5425a36e2cd89b7e190bc6777a3118cd | |
parent | f1f3a3a10c48dfeabb33cf86432097a146eba9a8 (diff) | |
download | pkgsrc-f6ad535eda8f713b9bf859c2e275239e76c89483.tar.gz |
Fix crashing bug in mbsync on NetBSD 6. From Enami Tsugutumo in
PR pkg/49784.
-rw-r--r-- | mail/isync/Makefile | 3 | ||||
-rw-r--r-- | mail/isync/distinfo | 3 | ||||
-rw-r--r-- | mail/isync/patches/patch-src_socket.c | 29 |
3 files changed, 33 insertions, 2 deletions
diff --git a/mail/isync/Makefile b/mail/isync/Makefile index f6c703841c5..a3abdfb82d2 100644 --- a/mail/isync/Makefile +++ b/mail/isync/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.36 2014/10/09 14:06:39 wiz Exp $ +# $NetBSD: Makefile,v 1.37 2015/07/04 15:52:51 bsiegert Exp $ DISTNAME= isync-1.1.1 +PKGREVISION= 1 CATEGORIES= mail net MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=isync/} diff --git a/mail/isync/distinfo b/mail/isync/distinfo index 82f68f93022..437ed02cce7 100644 --- a/mail/isync/distinfo +++ b/mail/isync/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.13 2014/06/09 17:29:09 schmonz Exp $ +$NetBSD: distinfo,v 1.14 2015/07/04 15:52:51 bsiegert Exp $ SHA1 (isync-1.1.1.tar.gz) = be759ff7e7e141b91fc242284ddeb256d54a5567 RMD160 (isync-1.1.1.tar.gz) = a8207433d368d621da81b1c68540e0838c391c0f @@ -7,3 +7,4 @@ SHA1 (patch-ae) = e1a1badcb99fe6089a15a259985933aceedfc110 SHA1 (patch-af) = f3803de6c97733fa5fd17ab89dbd75910eec3301 SHA1 (patch-src_Makefile.in) = f946bff2e0a2b9a50fdcc752b2d5e3767f42a03b SHA1 (patch-src_compat_Makefile.in) = 82ee8cb1abcb8479865856b085c2ca016242b6dd +SHA1 (patch-src_socket.c) = 04d2e9d4db870b00ebd3bc9eb9571de581dee0a7 diff --git a/mail/isync/patches/patch-src_socket.c b/mail/isync/patches/patch-src_socket.c new file mode 100644 index 00000000000..a0b6ae2483e --- /dev/null +++ b/mail/isync/patches/patch-src_socket.c @@ -0,0 +1,29 @@ +$NetBSD: patch-src_socket.c,v 1.3 2015/07/04 15:52:51 bsiegert Exp $ +Prevent mbsync from crashing, PR pkg/49784. + +--- src/socket.c.orig 2015-07-04 15:47:16.000000000 +0000 ++++ src/socket.c +@@ -477,7 +477,10 @@ static void + socket_connected( conn_t *conn ) + { + #ifdef HAVE_IPV6 +- freeaddrinfo( conn->addrs ); ++ if ( conn->addrs ) { ++ freeaddrinfo( conn->addrs ); ++ conn->addrs = NULL; ++ } + #endif + conf_fd( conn->fd, 0, POLLIN ); + conn->state = SCK_READY; +@@ -488,7 +491,10 @@ static void + socket_connect_bail( conn_t *conn ) + { + #ifdef HAVE_IPV6 +- freeaddrinfo( conn->addrs ); ++ if ( conn->addrs ) { ++ freeaddrinfo( conn->addrs ); ++ conn->addrs = NULL; ++ } + #endif + free( conn->name ); + conn->name = 0; |