Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 43395 Details for
Bug 70240
net-firewall/iptables: problem with automatically loading modules
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch used by debian for their iptables_1.2.11-4
006-modprobe.patch (text/plain), 1.33 KB, created by
Matthias Geerdsen (RETIRED)
on 2004-11-06 03:21:20 UTC
(
hide
)
Description:
patch used by debian for their iptables_1.2.11-4
Filename:
MIME Type:
Creator:
Matthias Geerdsen (RETIRED)
Created:
2004-11-06 03:21:20 UTC
Size:
1.33 KB
patch
obsolete
>--- old/iptables_profectio/iptables.c (revision 3243) >+++ new/iptables_profectio/iptables.c (working copy) >@@ -1593,15 +1593,17 @@ > int procfile; > char *ret; > >+#define PROCFILE_BUFSIZ 1024 > procfile = open(PROC_SYS_MODPROBE, O_RDONLY); > if (procfile < 0) > return NULL; > >- ret = malloc(1024); >+ ret = (char *) malloc(PROCFILE_BUFSIZ); > if (ret) { >- switch (read(procfile, ret, 1024)) { >+ memset(ret, 0, PROCFILE_BUFSIZ); >+ switch (read(procfile, ret, PROCFILE_BUFSIZ)) { > case -1: goto fail; >- case 1024: goto fail; /* Partial read. Wierd */ >+ case PROCFILE_BUFSIZ: goto fail; /* Partial read. Wierd */ > } > if (ret[strlen(ret)-1]=='\n') > ret[strlen(ret)-1]=0; > >--- old/iptables_profectio/ip6tables.c (revision 3243) >+++ new/iptables_profectio/ip6tables.c (working copy) >@@ -1595,15 +1595,17 @@ > int procfile; > char *ret; > >+#define PROCFILE_BUFSIZ 1024 > procfile = open(PROC_SYS_MODPROBE, O_RDONLY); > if (procfile < 0) > return NULL; > >- ret = malloc(1024); >+ ret = malloc(PROCFILE_BUFSIZ); > if (ret) { >- switch (read(procfile, ret, 1024)) { >+ memset(ret, 0, PROCFILE_BUFSIZ); >+ switch (read(procfile, ret, PROCFILE_BUFSIZ)) { > case -1: goto fail; >- case 1024: goto fail; /* Partial read. Wierd */ >+ case PROCFILE_BUFSIZ: goto fail; /* Partial read. Wierd */ > } > if (ret[strlen(ret)-1]=='\n') > ret[strlen(ret)-1]=0; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 70240
: 43395