diff options
author | vanilla <vanilla@FreeBSD.org> | 2001-06-26 09:53:39 +0000 |
---|---|---|
committer | vanilla <vanilla@FreeBSD.org> | 2001-06-26 09:53:39 +0000 |
commit | e4a84f36e9f47d28a609599b98ce10b8631519ce (patch) | |
tree | 2ed757137cad4f4c69423b7967dde12faacd12e4 /mail/cucipop | |
parent | 5e09444f6e398c0f0ae8729824a884bd78aee8b0 (diff) | |
download | FreeBSD-ports-e4a84f36e9f47d28a609599b98ce10b8631519ce.zip FreeBSD-ports-e4a84f36e9f47d28a609599b98ce10b8631519ce.tar.gz |
Fix segfaults when accessing a mailbox with 512 messages.
PR: ports/28099
Submitted by: Andre Albsmeier <andre.albsmeier@mchp.siemens.de>
Diffstat (limited to 'mail/cucipop')
-rw-r--r-- | mail/cucipop/files/patch-ac | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/mail/cucipop/files/patch-ac b/mail/cucipop/files/patch-ac index 1acb21e..391df7a 100644 --- a/mail/cucipop/files/patch-ac +++ b/mail/cucipop/files/patch-ac @@ -1,6 +1,6 @@ ---- cucipop.c.bak Wed May 13 20:57:39 1998 -+++ cucipop.c Sun Mar 28 17:08:28 1999 -@@ -45,7 +45,7 @@ +--- cucipop.c.orig Tue Jun 26 17:51:11 2001 ++++ cucipop.c Tue Jun 26 17:51:50 2001 +@@ -48,7 +48,7 @@ #include "hsort.h" #ifdef APOP @@ -9,3 +9,12 @@ #endif #define MD5_DIGLEN 16 +@@ -314,7 +314,7 @@ + + static void addblock(const off_t start) + { if(msgs_filled==msgs_max&& +- !(msgs=realloc(msgs,(msgs_max+=GROWSTEP)*sizeof*msgs))) ++ !(msgs=realloc(msgs,((msgs_max+=GROWSTEP)+1)*sizeof*msgs))) + outofmem(); + msgs[msgs_filled].order=msgs_filled;msgs[msgs_filled].start=start; + msgs[msgs_filled].virtsize=0;msgs[msgs_filled++].deleted=0; |