Page MenuHomeFreeBSD

D31300.id92722.diff
No OneTemporary

D31300.id92722.diff

Index: sbin/dumpon/dumpon.c
===================================================================
--- sbin/dumpon/dumpon.c
+++ sbin/dumpon/dumpon.c
@@ -547,6 +547,22 @@
if (strcmp(argv[0], "off") == 0) {
rflag = true;
dev = _PATH_DEVNULL;
+
+ /*
+ * Netdump has its own configuration tracking that
+ * is not removed when using /dev/null.
+ */
+ fd = open(_PATH_NETDUMP, O_RDONLY);
+ if (fd != -1) {
+ bzero(&ndconf, sizeof(ndconf));
+ ndconf.kda_index = KDA_REMOVE_ALL;
+ ndconf.kda_af = AF_INET;
+ error = ioctl(fd, DIOCSKERNELDUMP, &ndconf);
+ if (error != 0)
+ err(1, "ioctl(%s, DIOCSKERNELDUMP)",
+ _PATH_NETDUMP);
+ close(fd);
+ }
} else
dev = argv[0];
netdump = false;

File Metadata

Mime Type
text/plain
Expires
Sat, Dec 13, 1:15 PM (18 h, 37 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26931895
Default Alt Text
D31300.id92722.diff (742 B)

Event Timeline