aboutsummaryrefslogtreecommitdiffstats
path: root/main/net-snmp/netsnmp-swinst-crash.patch
diff options
context:
space:
mode:
Diffstat (limited to 'main/net-snmp/netsnmp-swinst-crash.patch')
-rw-r--r--main/net-snmp/netsnmp-swinst-crash.patch23
1 files changed, 12 insertions, 11 deletions
diff --git a/main/net-snmp/netsnmp-swinst-crash.patch b/main/net-snmp/netsnmp-swinst-crash.patch
index 5502ddb28a..58c368facc 100644
--- a/main/net-snmp/netsnmp-swinst-crash.patch
+++ b/main/net-snmp/netsnmp-swinst-crash.patch
@@ -1,12 +1,13 @@
---- net-snmp-5.7.1/agent/mibgroup/host/data_access/swinst_pkginfo.c
-+++ /home/fabled//net-snmp-5.7.1.patched/agent/mibgroup/host/data_access/swinst_pkginfo.c
-@@ -140,7 +140,8 @@
- memcpy( entry->swDate, cp, date_len );
- entry->swDate_len = date_len;
+--- a/agent/mibgroup/host/data_access/swinst_pkginfo.c.orig
++++ b/agent/mibgroup/host/data_access/swinst_pkginfo.c
+@@ -207,7 +207,9 @@
+ memcpy( entry->swDate, cp, date_len );
+ entry->swDate_len = date_len;
+ }
+- closedir( d );
++ if (d != NULL)
++ closedir( d );
++
+ #ifdef HAVE_LIBPKG
}
-- closedir( d );
-+ if (d != NULL)
-+ closedir( d );
-
- DEBUGMSGTL(("swinst:load:arch"," loaded %d entries\n",
- (int)CONTAINER_SIZE(container)));
+ #endif