aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/bsnmpd
diff options
context:
space:
mode:
authorPedro F. Giffuni <pfg@FreeBSD.org>2017-10-28 21:26:49 +0000
committerPedro F. Giffuni <pfg@FreeBSD.org>2017-10-28 21:26:49 +0000
commit7e7315b5428a63d1bc4be4b5295da5a493c02c98 (patch)
tree8508f66935c07d7b1ac9a52f8a3e2cd9427e00bc /usr.sbin/bsnmpd
parent0f23ab8aac1b8c302cf94245b469d15b52f8b76a (diff)
downloadsrc-7e7315b5428a63d1bc4be4b5295da5a493c02c98.tar.gz
src-7e7315b5428a63d1bc4be4b5295da5a493c02c98.zip
Notes
Diffstat (limited to 'usr.sbin/bsnmpd')
-rw-r--r--usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c b/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c
index 8216acce27dc..a360898e6785 100644
--- a/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c
+++ b/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c
@@ -479,7 +479,9 @@ again:
} else {
if (read_len == sizeof(buf))
goto again;
- refresh_device_tbl(1);
+ /* Only refresh device table on a device add or remove event. */
+ if (buf[0] == '+' || buf[0] == '-')
+ refresh_device_tbl(1);
}
}