Ouch, forgotten to attach.
#! /bin/sh /usr/share/dpatch/dpatch-run
## 30sysctl_off_by_one.dpatch by  <[EMAIL PROTECTED]>
##
## DP: Fix off-by-one error. If tmpname is a directory, a trailing slash
## DP: is appended before the buffer is passed on to DisplayAll()...
## DP: but that slash doesn't fit in the (really tightly) allocated buffer.

@DPATCH@
--- procps-3.2.7.orig/sysctl.c  2007-08-06 02:29:12.000000000 +0200
+++ procps-3.2.7/sysctl.c       2007-08-06 02:27:18.000000000 +0200
@@ -135,7 +135,7 @@
    }
 
    /* used to open the file */
-   tmpname = malloc(strlen(name)+strlen(PROC_PATH)+1);
+   tmpname = malloc(strlen(name)+strlen(PROC_PATH)+2);
    strcpy(tmpname, PROC_PATH);
    strcat(tmpname, name); 
    slashdot(tmpname+strlen(PROC_PATH),'.','/'); /* change . to / */

Attachment: signature.asc
Description: Digital signature

Reply via email to