From af620e968cae9fe1e3dbaf9b20efa019ccd3d8e9 Mon Sep 17 00:00:00 2001 From: Jun Kuriyama Date: Tue, 9 Apr 2002 00:31:17 +0000 Subject: Upgrade to 4.2.4. Some of our patches are integrated into original distribution. Enable diskio mib-module by default. --- net-mgmt/net-snmp53/files/patch-hr_storage.c | 33 ++++++++++++---------------- 1 file changed, 14 insertions(+), 19 deletions(-) (limited to 'net-mgmt/net-snmp53/files/patch-hr_storage.c') diff --git a/net-mgmt/net-snmp53/files/patch-hr_storage.c b/net-mgmt/net-snmp53/files/patch-hr_storage.c index 063c5bcc62ff..0c5381602966 100644 --- a/net-mgmt/net-snmp53/files/patch-hr_storage.c +++ b/net-mgmt/net-snmp53/files/patch-hr_storage.c @@ -1,39 +1,34 @@ ---- agent/mibgroup/host/hr_storage.c.orig Thu Mar 22 14:27:21 2001 -+++ agent/mibgroup/host/hr_storage.c Thu Oct 11 12:19:18 2001 -@@ -523,8 +523,18 @@ +--- agent/mibgroup/host/hr_storage.c.orig Fri Feb 8 19:42:25 2002 ++++ agent/mibgroup/host/hr_storage.c Sat Feb 16 23:37:31 2002 +@@ -583,7 +583,15 @@ for (i = 0; i < sizeof(mbstat.m_mtypes)/sizeof(mbstat.m_mtypes[0]); i++) long_return += mbstat.m_mtypes[i]; #elif defined(MBSTAT_SYMBOL) -+#if __FreeBSD_version < 500021 ++#if !defined(__FreeBSD__) || __FreeBSD_version < 500021 long_return = mbstat.m_mbufs; - #else -+#if __FreeBSD_version < 500024 ++#elif __FreeBSD_version < 500024 + /* mbuf stats disabled */ + return NULL; +#else + /* XXX TODO: implement new method */ + return NULL; +#endif -+#endif -+#else + #elif defined(NO_DUMMY_VALUES) return NULL; - #endif - break; -@@ -562,7 +572,17 @@ - long_return = (mbpool.pr_nget - mbpool.pr_nput)*mbpool.pr_size - + (mclpool.pr_nget - mclpool.pr_nput)*mclpool.pr_size; + #else +@@ -634,7 +642,15 @@ + + (mclpool.pr_nget - mclpool.pr_nput) + * mclpool.pr_size; #elif defined(MBSTAT_SYMBOL) -+#if __FreeBSD_version < 500021 ++#if !defined(__FreeBSD__) || __FreeBSD_version < 500021 long_return = mbstat.m_clusters - mbstat.m_clfree; /* unlikely, but... */ -+#else -+#if __FreeBSD_version < 500024 ++#elif __FreeBSD_version < 500024 + /* mbuf stats disabled */ + return NULL; +#else + /* XXX TODO: implement new method */ + return NULL; +#endif -+#endif - #else + #elif defined(NO_DUMMY_VALUES) return NULL; - #endif + #else -- cgit v1.2.3