fix memory corruption problem

This commit is contained in:
Bob Halley
1999-10-27 16:37:34 +00:00
parent 8e8964cd7e
commit 18670af94d

View File

@@ -387,7 +387,7 @@ sig_fromfile(char *path, isc_buffer_t *iscbuf) {
return(1);
}
buf = (char *) malloc(((sb.st_size / 2) + 1) * sizeof(unsigned char));
buf = (char *) malloc((sb.st_size + 1) * sizeof(unsigned char));
if (buf == NULL) {
t_info("malloc failed, errno == %d\n", errno);
return(1);