summaryrefslogtreecommitdiff
path: root/net-mgmt/net-snmp/files/patch-hr_system.c
diff options
context:
space:
mode:
authorJun Kuriyama <kuriyama@FreeBSD.org>2004-04-03 13:49:22 +0000
committerJun Kuriyama <kuriyama@FreeBSD.org>2004-04-03 13:49:22 +0000
commitee9dbc37046b2e56fd6f19a9808c9d094b0b983e (patch)
tree27e9c74dba2cda53eccb11d0ecf9207fe3350fe0 /net-mgmt/net-snmp/files/patch-hr_system.c
parentBROKEN on !i386: Does not compile (diff)
Upgrade to 5.1.1.
Diffstat (limited to 'net-mgmt/net-snmp/files/patch-hr_system.c')
-rw-r--r--net-mgmt/net-snmp/files/patch-hr_system.c26
1 files changed, 8 insertions, 18 deletions
diff --git a/net-mgmt/net-snmp/files/patch-hr_system.c b/net-mgmt/net-snmp/files/patch-hr_system.c
index a0271bdaf052..f2d810ac0771 100644
--- a/net-mgmt/net-snmp/files/patch-hr_system.c
+++ b/net-mgmt/net-snmp/files/patch-hr_system.c
@@ -1,21 +1,11 @@
---- agent/mibgroup/host/hr_system.c.orig Sat Mar 1 05:35:13 2003
-+++ agent/mibgroup/host/hr_system.c Sun Feb 8 17:39:50 2004
-@@ -280,7 +280,6 @@
- while ((utmp_p = getutent()) != NULL) {
+--- agent/mibgroup/host/hr_system.c.orig Mon Feb 23 02:29:34 2004
++++ agent/mibgroup/host/hr_system.c Sat Apr 3 00:00:24 2004
+@@ -596,6 +596,8 @@
#ifndef UTMP_HAS_NO_TYPE
- if (utmp_p->ut_type == USER_PROCESS) {
--#endif
- /* This block of code fixes zombie user PIDs in the
- utmp/utmpx file that would otherwise be counted as a
- current user */
-@@ -291,6 +290,10 @@
- }
- ++total;
- }
+ if (utmp_p->ut_type != USER_PROCESS)
+ continue;
+#else
+ if (*utmp_p->ut_name != '~')
-+ ++total;
-+#endif
- }
- endutent();
- return total;
+ #endif
+ #ifndef UTMP_HAS_NO_PID
+ /* This block of code fixes zombie user PIDs in the