From 8cef2fc6316b4adbba933286d9e9bbeec9a70f3c Mon Sep 17 00:00:00 2001 From: Reyk Floeter Date: Wed, 5 Dec 2007 22:52:51 +0000 Subject: - add support joel's OPENBSD-SENSORS-MIB; it will dump the current sensor status in a SNMP table. - some other minor changes --- usr.sbin/snmpd/mps.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'usr.sbin/snmpd/mps.c') diff --git a/usr.sbin/snmpd/mps.c b/usr.sbin/snmpd/mps.c index 8a7c90ef887..4a82511f285 100644 --- a/usr.sbin/snmpd/mps.c +++ b/usr.sbin/snmpd/mps.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mps.c,v 1.1 2007/12/05 09:22:44 reyk Exp $ */ +/* $OpenBSD: mps.c,v 1.2 2007/12/05 22:52:50 reyk Exp $ */ /* * Copyright (c) 2007 Reyk Floeter @@ -377,12 +377,12 @@ mps_insert(struct oid *oid) } void -mps_mibtree(struct oid *oids, size_t n) +mps_mibtree(struct oid *oids) { struct oid *oid; size_t i; - for (i = 0; i < n; i++) { + for (i = 0; oids[i].o_name != NULL; i++) { oid = &oids[i]; mps_oidlen(&oid->o_id); if ((oid->o_flags & OID_TABLE) && oid->o_get == NULL) -- cgit v1.2.3