patch-src_knockd_c 520 B

123456789101112
  1. $Id: update-patches 24 2008-08-31 14:56:13Z wbx $
  2. --- knock-0.5.orig/src/knockd.c 2005-06-27 07:11:34.000000000 +0200
  3. +++ knock-0.5/src/knockd.c 2009-05-29 17:03:55.776378324 +0200
  4. @@ -1064,7 +1064,7 @@ char* get_ip(const char* iface, char *bu
  5. return(NULL);
  6. }
  7. - bzero((void*)(&ifr.ifr_name), sizeof(ifr.ifr_name));
  8. + memset((void*)(&ifr.ifr_name), 0, sizeof(ifr.ifr_name));
  9. strncpy(ifr.ifr_name, iface, sizeof(ifr.ifr_name)-1);
  10. ifr.ifr_name[sizeof(ifr.ifr_name)-1] = '\0';
  11. if(ioctl(s, SIOCGIFADDR, &ifr)) {