|
|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
Index: Makefile.in
|
|
|
|
|
--- Makefile.in.orig 2010-09-10 06:23:07.000000000 +0200
|
|
|
|
|
+++ Makefile.in 2010-10-09 09:56:09.000000000 +0200
|
|
|
|
|
@@ -18,7 +18,7 @@
|
|
|
|
|
--- Makefile.in.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ Makefile.in 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -19,7 +19,7 @@
|
|
|
|
|
INCLUDESUBDIR=system
|
|
|
|
|
INCLUDESUBDIRHEADERS= aix.h bsd.h bsdi3.h bsdi4.h bsdi.h cygwin.h \
|
|
|
|
|
darwin.h darwin7.h darwin8.h darwin9.h darwin10.h dragonfly.h dynix.h \
|
|
|
|
|
@ -11,8 +11,8 @@ Index: Makefile.in
|
|
|
|
|
hpux.h irix.h linux.h mingw32.h mips.h netbsd.h openbsd.h osf5.h \
|
|
|
|
|
solaris2.3.h solaris2.4.h solaris2.5.h solaris2.6.h \
|
|
|
|
|
Index: agent/auto_nlist.c
|
|
|
|
|
--- agent/auto_nlist.c.orig 2010-07-29 16:58:47.000000000 +0200
|
|
|
|
|
+++ agent/auto_nlist.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
--- agent/auto_nlist.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/auto_nlist.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -53,6 +53,7 @@
|
|
|
|
|
}
|
|
|
|
|
if (*ptr == 0) {
|
|
|
|
|
@ -22,9 +22,9 @@ Index: agent/auto_nlist.c
|
|
|
|
|
it->left = 0;
|
|
|
|
|
it->right = 0;
|
|
|
|
|
Index: agent/mibgroup/mibII/tcp.c
|
|
|
|
|
--- agent/mibgroup/mibII/tcp.c.orig 2010-08-13 17:04:33.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/mibII/tcp.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -87,7 +87,7 @@
|
|
|
|
|
--- agent/mibgroup/mibII/tcp.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/mibII/tcp.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -88,7 +88,7 @@
|
|
|
|
|
* But only define it under FreeBSD, since it
|
|
|
|
|
* breaks other systems (notable AIX)
|
|
|
|
|
*/
|
|
|
|
|
@ -34,9 +34,9 @@ Index: agent/mibgroup/mibII/tcp.c
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
Index: agent/mibgroup/mibII/tcpTable.c
|
|
|
|
|
--- agent/mibgroup/mibII/tcpTable.c.orig 2010-06-16 15:13:25.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/mibII/tcpTable.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -104,6 +104,11 @@
|
|
|
|
|
--- agent/mibgroup/mibII/tcpTable.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/mibII/tcpTable.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -110,6 +110,11 @@
|
|
|
|
|
#define TCPTABLE_REMOTEPORT pcb.inp_fport
|
|
|
|
|
#define TCPTABLE_IS_LINKED_LIST
|
|
|
|
|
|
|
|
|
|
@ -48,7 +48,7 @@ Index: agent/mibgroup/mibII/tcpTable.c
|
|
|
|
|
#endif /* linux */
|
|
|
|
|
#endif /* WIN32 cygwin */
|
|
|
|
|
#endif /* solaris2 */
|
|
|
|
|
@@ -867,12 +872,17 @@
|
|
|
|
|
@@ -892,12 +897,17 @@
|
|
|
|
|
nnew = SNMP_MALLOC_TYPEDEF(netsnmp_inpcb);
|
|
|
|
|
if (!nnew)
|
|
|
|
|
break;
|
|
|
|
|
@ -64,12 +64,12 @@ Index: agent/mibgroup/mibII/tcpTable.c
|
|
|
|
|
sizeof(struct inpcb));
|
|
|
|
|
+#endif
|
|
|
|
|
|
|
|
|
|
nnew->inp_next = tcp_head;
|
|
|
|
|
tcp_head = nnew;
|
|
|
|
|
if (nnew->pcb.inp_vflag & INP_IPV6)
|
|
|
|
|
free(nnew);
|
|
|
|
|
Index: agent/mibgroup/ucd-snmp/diskio.c
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/diskio.c.orig 2010-08-13 17:04:33.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/diskio.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -618,6 +618,20 @@
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/diskio.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/diskio.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -800,6 +800,20 @@
|
|
|
|
|
case DISKIO_DEVICE:
|
|
|
|
|
*var_len = strlen(stat->dinfo->devices[indx].device_name);
|
|
|
|
|
return (u_char *) stat->dinfo->devices[indx].device_name;
|
|
|
|
|
@ -90,7 +90,7 @@ Index: agent/mibgroup/ucd-snmp/diskio.c
|
|
|
|
|
case DISKIO_NREAD:
|
|
|
|
|
#if defined(freebsd5) && __FreeBSD_version >= 500107
|
|
|
|
|
long_ret = (signed long) stat->dinfo->devices[indx].bytes[DEVSTAT_READ];
|
|
|
|
|
@@ -675,6 +689,7 @@
|
|
|
|
|
@@ -857,6 +871,7 @@
|
|
|
|
|
case DISKIO_LA15:
|
|
|
|
|
long_ret = devloads[indx].la15;
|
|
|
|
|
return (u_char *) & long_ret;
|
|
|
|
|
@ -99,27 +99,27 @@ Index: agent/mibgroup/ucd-snmp/diskio.c
|
|
|
|
|
default:
|
|
|
|
|
ERROR_MSG("diskio.c: don't know how to handle this request.");
|
|
|
|
|
Index: agent/mibgroup/ucd-snmp/memory_solaris2.c
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/memory_solaris2.c.orig 2008-10-21 23:10:43.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/memory_solaris2.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/memory_solaris2.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/memory_solaris2.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -1,3 +1,4 @@
|
|
|
|
|
+#undef _FILE_OFFSET_BITS /* swapctl doesn't support 64bit off_t */
|
|
|
|
|
#include <net-snmp/net-snmp-config.h> /* local SNMP configuration details */
|
|
|
|
|
#if HAVE_STRING_H
|
|
|
|
|
#include <string.h>
|
|
|
|
|
Index: agent/mibgroup/ucd-snmp/proc.c
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/proc.c.orig 2010-07-29 16:58:47.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/proc.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
--- agent/mibgroup/ucd-snmp/proc.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/ucd-snmp/proc.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -1,3 +1,6 @@
|
|
|
|
|
+#ifdef solaris2
|
|
|
|
|
+#undef _FILE_OFFSET_BITS /* solaris procfs doesn't support 64bit off_t */
|
|
|
|
|
+#endif
|
|
|
|
|
#include <net-snmp/net-snmp-config.h>
|
|
|
|
|
#include <net-snmp/net-snmp-features.h>
|
|
|
|
|
|
|
|
|
|
#ifdef solaris2
|
|
|
|
|
Index: agent/mibgroup/util_funcs.c
|
|
|
|
|
--- agent/mibgroup/util_funcs.c.orig 2010-05-16 20:12:40.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/util_funcs.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -457,6 +457,9 @@
|
|
|
|
|
--- agent/mibgroup/util_funcs.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/mibgroup/util_funcs.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -477,6 +477,9 @@
|
|
|
|
|
int fd[2][2], i, cnt;
|
|
|
|
|
char ctmp[STRMAX], *cptr1, *cptr2, argvs[STRMAX], **argv,
|
|
|
|
|
**aptr;
|
|
|
|
|
@ -130,32 +130,32 @@ Index: agent/mibgroup/util_funcs.c
|
|
|
|
|
* Setup our pipes
|
|
|
|
|
*/
|
|
|
|
|
Index: agent/snmpd.c
|
|
|
|
|
--- agent/snmpd.c.orig 2010-08-17 20:31:31.000000000 +0200
|
|
|
|
|
+++ agent/snmpd.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -429,7 +429,7 @@
|
|
|
|
|
--- agent/snmpd.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ agent/snmpd.c 2011-07-02 10:33:57.000000000 +0200
|
|
|
|
|
@@ -440,7 +440,7 @@
|
|
|
|
|
int log_set = 0;
|
|
|
|
|
int uid = 0, gid = 0;
|
|
|
|
|
int agent_mode = -1;
|
|
|
|
|
char *cptr, **argvptr;
|
|
|
|
|
- char *pid_file = NULL;
|
|
|
|
|
+ char *pid_file = "@l_prefix@/var/snmp/snmpd.pid";
|
|
|
|
|
char option_compatability[] = "-Le";
|
|
|
|
|
#if HAVE_GETPID
|
|
|
|
|
int fd;
|
|
|
|
|
Index: apps/snmptrapd.c
|
|
|
|
|
--- apps/snmptrapd.c.orig 2010-08-13 20:50:07.000000000 +0200
|
|
|
|
|
+++ apps/snmptrapd.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -652,6 +652,7 @@
|
|
|
|
|
--- apps/snmptrapd.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ apps/snmptrapd.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -657,6 +657,7 @@
|
|
|
|
|
*/
|
|
|
|
|
#if HAVE_GETPID
|
|
|
|
|
strcat(options, "p:");
|
|
|
|
|
+ parse_config_pidFile(NULL, "@l_prefix@/var/snmp/snmptrapd.pid");
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#ifdef WIN32
|
|
|
|
|
#ifndef NETSNMP_FEATURE_REMOVE_LOGGING_SYSLOG
|
|
|
|
|
Index: include/net-snmp/library/system.h
|
|
|
|
|
--- include/net-snmp/library/system.h.orig 2010-03-25 16:06:26.000000000 +0100
|
|
|
|
|
+++ include/net-snmp/library/system.h 2010-10-09 09:56:40.000000000 +0200
|
|
|
|
|
@@ -141,7 +141,8 @@
|
|
|
|
|
--- include/net-snmp/library/system.h.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ include/net-snmp/library/system.h 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -155,7 +155,8 @@
|
|
|
|
|
#endif
|
|
|
|
|
#ifndef HAVE_SETENV
|
|
|
|
|
NETSNMP_IMPORT
|
|
|
|
|
@ -166,26 +166,26 @@ Index: include/net-snmp/library/system.h
|
|
|
|
|
|
|
|
|
|
NETSNMP_IMPORT
|
|
|
|
|
Index: include/net-snmp/system/freebsd8.h
|
|
|
|
|
--- include/net-snmp/system/freebsd8.h.orig 2010-02-14 20:29:08.000000000 +0100
|
|
|
|
|
+++ include/net-snmp/system/freebsd8.h 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
--- include/net-snmp/system/freebsd8.h.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ include/net-snmp/system/freebsd8.h 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -1,3 +1,6 @@
|
|
|
|
|
+/* freebsd8 is a superset of freebsd7 */
|
|
|
|
|
+#include "freebsd7.h"
|
|
|
|
|
+#define freebsd7 freebsd7
|
|
|
|
|
/* freebsd8 is a superset of freebsd4 */
|
|
|
|
|
#include "freebsd4.h"
|
|
|
|
|
#define freebsd4 freebsd4
|
|
|
|
|
#include "freebsd7.h"
|
|
|
|
|
#define freebsd7 freebsd7
|
|
|
|
|
Index: include/net-snmp/system/freebsd9.h
|
|
|
|
|
--- include/net-snmp/system/freebsd9.h.orig 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
+++ include/net-snmp/system/freebsd9.h 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
--- include/net-snmp/system/freebsd9.h.orig 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
+++ include/net-snmp/system/freebsd9.h 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
+/* freebsd9 is a superset of freebsd8 */
|
|
|
|
|
+#include "freebsd8.h"
|
|
|
|
|
+#define freebsd8 freebsd8
|
|
|
|
|
Index: snmplib/system.c
|
|
|
|
|
--- snmplib/system.c.orig 2010-07-29 16:58:47.000000000 +0200
|
|
|
|
|
+++ snmplib/system.c 2010-10-09 09:08:23.000000000 +0200
|
|
|
|
|
@@ -837,7 +837,7 @@
|
|
|
|
|
--- snmplib/system.c.orig 2011-07-02 00:35:46.000000000 +0200
|
|
|
|
|
+++ snmplib/system.c 2011-07-02 09:23:36.000000000 +0200
|
|
|
|
|
@@ -1044,7 +1044,7 @@
|
|
|
|
|
|
|
|
|
|
#ifndef HAVE_SETENV
|
|
|
|
|
int
|
|
|
|
|
|