]> git.ipfire.org Git - ipfire-3.x.git/blob - dev86/patches/02-dev86-0.16.17-fortify.patch
Remove xen
[ipfire-3.x.git] / dev86 / patches / 02-dev86-0.16.17-fortify.patch
1 --- dev86-0.16.17/bcc/bcc.c
2 +++ dev86-0.16.17/bcc/bcc.c
3 @@ -19,6 +19,7 @@
4 #ifdef __STDC__
5 #include <stdlib.h>
6 #ifndef MSDOS
7 +#include <limits.h>
8 #include <unistd.h>
9 #endif
10 #else
11 @@ -596,12 +597,17 @@
12 }
13 }
14
15 -void
16 -command_reset()
17 -{
18 #ifndef MAXPATHLEN
19 +#ifdef PATH_MAX
20 +#define MAXPATHLEN PATH_MAX
21 +#else
22 #define MAXPATHLEN 1024
23 #endif
24 +#endif
25 +
26 +void
27 +command_reset()
28 +{
29 char buf[MAXPATHLEN];
30 char ** prefix;
31 char * saved_cmd;
32 @@ -1308,11 +1314,7 @@
33
34 for(d=s=ptr; d && *s; s=d)
35 {
36 -#ifdef MAXPATHLEN
37 char buf[MAXPATHLEN];
38 -#else
39 - char buf[1024];
40 -#endif
41
42 free(temp);
43 d=strchr(s, ':');