102-iptables-disable-modprobe.patch 606 B

123456789101112131415161718192021222324252627
  1. --- a/libxtables/xtables.c
  2. +++ b/libxtables/xtables.c
  3. @@ -475,7 +475,7 @@ char *xtables_strdup(const char *s)
  4. return dup;
  5. }
  6. -static char *get_modprobe(void)
  7. +__attribute__((unused)) static char *get_modprobe(void)
  8. {
  9. int procfile;
  10. char *ret;
  11. @@ -505,6 +505,7 @@ static char *get_modprobe(void)
  12. int xtables_insmod(const char *modname, const char *modprobe, bool quiet)
  13. {
  14. +#if 0
  15. char *buf = NULL;
  16. char *argv[4];
  17. int status;
  18. @@ -539,6 +540,7 @@ int xtables_insmod(const char *modname,
  19. free(buf);
  20. if (WIFEXITED(status) && WEXITSTATUS(status) == 0)
  21. return 0;
  22. +#endif
  23. return -1;
  24. }