2
1

netsnmp-swinst-crash.patch 625 B

1234567891011121314151617
  1. Fixes runtime error with uClibc (and possibly others).
  2. Original patch and bug description:
  3. http://sourceforge.net/tracker/?func=detail&aid=3436528&group_id=12694&atid=312694
  4. --- net-snmp-5.7.1/agent/mibgroup/host/data_access/swinst_pkginfo.c
  5. +++ /home/fabled//net-snmp-5.7.1.patched/agent/mibgroup/host/data_access/swinst_pkginfo.c
  6. @@ -140,7 +140,8 @@
  7. memcpy( entry->swDate, cp, date_len );
  8. entry->swDate_len = date_len;
  9. }
  10. - closedir( d );
  11. + if (d != NULL)
  12. + closedir( d );
  13. DEBUGMSGTL(("swinst:load:arch"," loaded %d entries\n",
  14. (int)CONTAINER_SIZE(container)));