Package: procmail / 3.22-24

23 Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
From: Santiago Vila <sanvila@debian.org>
Subject: Fixed off-by-1 memory allocation error
Bug-Debian: http://bugs.debian.org/474298
Bug-Debian: http://bugs.debian.org/484352
X-Debian-version: 3.22-17

--- a/src/mailfold.c
+++ b/src/mailfold.c
@@ -205,7 +205,7 @@
   if(linkfolder)		    /* any additional directories specified? */
    { size_t blen;
      if(blen=Tmnate-linkfolder)		       /* copy the names into safety */
-	Tmnate=(linkfolder=tmemmove(malloc(blen),linkfolder,blen))+blen;
+	Tmnate=(linkfolder=tmemmove(malloc(blen+1),linkfolder,blen))+blen;
      else
 	linkfolder=0;
    }