aboutsummaryrefslogtreecommitdiff
path: root/net-mgmt/net-snmp-devel/files
diff options
context:
space:
mode:
Diffstat (limited to 'net-mgmt/net-snmp-devel/files')
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-agent_index.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-agent_read_config.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-agent_registry.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-asn1.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-at.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-auto_nlist.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-callback.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-default_store.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-diskio.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-interfaces.c16
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-keytools.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-lcd_time.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-master.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-master_admin.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-mib.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-net-snmp-includes.h13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-oid_stash.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-parse.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-scapi.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmpUDPDomain.c11
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmp_auth.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmp_debug.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmp_logging.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmp_transport.c12
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmp_vars.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-snmpusm.c16
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-subagent.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-sysORTable.c13
-rw-r--r--net-mgmt/net-snmp-devel/files/patch-tools.c12
29 files changed, 346 insertions, 19 deletions
diff --git a/net-mgmt/net-snmp-devel/files/patch-agent_index.c b/net-mgmt/net-snmp-devel/files/patch-agent_index.c
new file mode 100644
index 000000000000..d6254de2148e
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-agent_index.c
@@ -0,0 +1,13 @@
+--- agent/agent_index.c.orig Mon Jan 24 09:14:39 2005
++++ agent/agent_index.c Mon Jan 24 09:14:55 2005
+@@ -39,10 +39,6 @@
+ #include <netinet/in.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+ #include <net-snmp/agent/agent_callbacks.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-agent_read_config.c b/net-mgmt/net-snmp-devel/files/patch-agent_read_config.c
new file mode 100644
index 000000000000..d38b96de7668
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-agent_read_config.c
@@ -0,0 +1,13 @@
+--- agent/agent_read_config.c.orig Mon Jan 24 09:12:58 2005
++++ agent/agent_read_config.c Mon Jan 24 09:13:13 2005
+@@ -84,10 +84,6 @@
+ #include <inet/mib2.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #if HAVE_UNISTD_H
+ #include <unistd.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-agent_registry.c b/net-mgmt/net-snmp-devel/files/patch-agent_registry.c
new file mode 100644
index 000000000000..4eab10a699f9
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-agent_registry.c
@@ -0,0 +1,13 @@
+--- agent/agent_registry.c.orig Mon Jan 24 09:14:00 2005
++++ agent/agent_registry.c Mon Jan 24 09:14:08 2005
+@@ -51,10 +51,6 @@
+ #include <netinet/in.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+ #include <net-snmp/agent/agent_callbacks.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-asn1.c b/net-mgmt/net-snmp-devel/files/patch-asn1.c
new file mode 100644
index 000000000000..477a909b07b9
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-asn1.c
@@ -0,0 +1,12 @@
+--- snmplib/asn1.c.orig Tue Jan 25 10:09:35 2005
++++ snmplib/asn1.c Tue Jan 25 10:09:55 2005
+@@ -181,6 +181,9 @@
+ #include <in.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-at.c b/net-mgmt/net-snmp-devel/files/patch-at.c
new file mode 100644
index 000000000000..363f1b07991e
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-at.c
@@ -0,0 +1,12 @@
+--- agent/mibgroup/mibII/at.c.orig Mon Jan 24 09:08:41 2005
++++ agent/mibgroup/mibII/at.c Mon Jan 24 09:08:58 2005
+@@ -90,9 +90,6 @@
+ #if HAVE_WINSOCK_H
+ #include <winsock.h>
+ #endif
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+
+ #ifdef hpux11
+ #include <sys/mib.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-auto_nlist.c b/net-mgmt/net-snmp-devel/files/patch-auto_nlist.c
new file mode 100644
index 000000000000..c15443a03afd
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-auto_nlist.c
@@ -0,0 +1,13 @@
+--- agent/auto_nlist.c.orig Mon Jan 24 09:11:07 2005
++++ agent/auto_nlist.c Mon Jan 24 09:11:24 2005
+@@ -21,10 +21,6 @@
+ #include <kvm.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/agent/auto_nlist.h>
+ #include "autonlist.h"
+ #include "kernel.h"
diff --git a/net-mgmt/net-snmp-devel/files/patch-callback.c b/net-mgmt/net-snmp-devel/files/patch-callback.c
new file mode 100644
index 000000000000..840d12c0d881
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-callback.c
@@ -0,0 +1,12 @@
+--- snmplib/callback.c.orig Tue Jan 25 10:19:39 2005
++++ snmplib/callback.c Tue Jan 25 10:19:53 2005
+@@ -34,6 +34,9 @@
+ #include <strings.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-default_store.c b/net-mgmt/net-snmp-devel/files/patch-default_store.c
new file mode 100644
index 000000000000..076ecec1431e
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-default_store.c
@@ -0,0 +1,12 @@
+--- snmplib/default_store.c.orig Tue Jan 25 10:20:31 2005
++++ snmplib/default_store.c Tue Jan 25 10:20:47 2005
+@@ -145,6 +145,9 @@
+ #include <winsock.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-diskio.c b/net-mgmt/net-snmp-devel/files/patch-diskio.c
new file mode 100644
index 000000000000..309f0a9d1a04
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-diskio.c
@@ -0,0 +1,12 @@
+--- ./agent/mibgroup/ucd-snmp/diskio.c.orig Mon Jan 24 23:35:53 2005
++++ ./agent/mibgroup/ucd-snmp/diskio.c Mon Jan 24 23:37:24 2005
+@@ -458,8 +458,8 @@
+ ERROR_MSG("Memory alloc failure - devla_getstats()\n");
+ return;
+ }
++ memset(lastat->dinfo, 0, sizeof(struct devinfo));
+ }
+- memset(lastat->dinfo, 0, sizeof(struct devinfo));
+
+ if ((GETDEVS(lastat)) == -1) {
+ ERROR_MSG("can't do getdevs()\n");
diff --git a/net-mgmt/net-snmp-devel/files/patch-interfaces.c b/net-mgmt/net-snmp-devel/files/patch-interfaces.c
index c9d465c00859..e69de29bb2d1 100644
--- a/net-mgmt/net-snmp-devel/files/patch-interfaces.c
+++ b/net-mgmt/net-snmp-devel/files/patch-interfaces.c
@@ -1,16 +0,0 @@
---- agent/mibgroup/mibII/interfaces.c.orig Sat Jun 8 00:18:03 2002
-+++ agent/mibgroup/mibII/interfaces.c Mon Jul 29 12:35:08 2002
-@@ -555,11 +555,9 @@
- ifp->ifm_type));
- }
- }
-- if (have_ifinfo && have_addr) {
-+ if (have_ifinfo) {
- return 0;
-- } else if (have_ifinfo && !(if_msg->ifm_flags & IFF_UP))
-- return 0;
-- else {
-+ } else {
- return -1;
- }
- }
diff --git a/net-mgmt/net-snmp-devel/files/patch-keytools.c b/net-mgmt/net-snmp-devel/files/patch-keytools.c
new file mode 100644
index 000000000000..b6bf51299bd9
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-keytools.c
@@ -0,0 +1,12 @@
+--- snmplib/keytools.c.orig Tue Jan 25 10:17:48 2005
++++ snmplib/keytools.c Tue Jan 25 10:18:07 2005
+@@ -32,6 +32,9 @@
+ #include <strings.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-lcd_time.c b/net-mgmt/net-snmp-devel/files/patch-lcd_time.c
new file mode 100644
index 000000000000..60d00ac6a960
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-lcd_time.c
@@ -0,0 +1,12 @@
+--- snmplib/lcd_time.c.orig Tue Jan 25 10:16:53 2005
++++ snmplib/lcd_time.c Tue Jan 25 10:17:10 2005
+@@ -38,6 +38,9 @@
+ #include <netinet/in.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-master.c b/net-mgmt/net-snmp-devel/files/patch-master.c
new file mode 100644
index 000000000000..12e553acc8e0
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-master.c
@@ -0,0 +1,13 @@
+--- agent/mibgroup/agentx/master.c.orig Mon Jan 24 09:16:00 2005
++++ agent/mibgroup/agentx/master.c Mon Jan 24 09:16:21 2005
+@@ -39,10 +39,6 @@
+ #endif
+ #include <errno.h>
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #if HAVE_UNISTD_H
+ #include <unistd.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-master_admin.c b/net-mgmt/net-snmp-devel/files/patch-master_admin.c
new file mode 100644
index 000000000000..cb4767076810
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-master_admin.c
@@ -0,0 +1,12 @@
+--- agent/mibgroup/agentx/master_admin.c.orig Mon Jan 24 09:18:07 2005
++++ agent/mibgroup/agentx/master_admin.c Mon Jan 24 09:18:15 2005
+@@ -35,9 +35,6 @@
+ #if HAVE_SYS_SOCKET_H
+ #include <sys/socket.h>
+ #endif
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-mib.c b/net-mgmt/net-snmp-devel/files/patch-mib.c
new file mode 100644
index 000000000000..af73abff4101
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-mib.c
@@ -0,0 +1,12 @@
+--- snmplib/mib.c.orig Tue Jan 25 10:01:11 2005
++++ snmplib/mib.c Tue Jan 25 10:02:02 2005
+@@ -75,6 +75,9 @@
+ #include <winsock.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-net-snmp-includes.h b/net-mgmt/net-snmp-devel/files/patch-net-snmp-includes.h
new file mode 100644
index 000000000000..cfb1dd29e981
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-net-snmp-includes.h
@@ -0,0 +1,13 @@
+--- include/net-snmp/net-snmp-includes.h.orig Mon Jan 24 08:24:47 2005
++++ include/net-snmp/net-snmp-includes.h Mon Jan 24 08:25:11 2005
+@@ -49,6 +49,10 @@
+ # endif
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
++
+ /*
+ * Must be right after system headers, but before library code for best usage
+ */
diff --git a/net-mgmt/net-snmp-devel/files/patch-oid_stash.c b/net-mgmt/net-snmp-devel/files/patch-oid_stash.c
new file mode 100644
index 000000000000..7978b27d587f
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-oid_stash.c
@@ -0,0 +1,13 @@
+--- snmplib/oid_stash.c.orig Mon Jan 24 09:43:04 2005
++++ snmplib/oid_stash.c Mon Jan 24 09:43:14 2005
+@@ -5,10 +5,6 @@
+ #include <stdlib.h>
+ #include <sys/types.h>
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+
+ /** @defgroup oid_stash Store and retrieve data referenced by an OID.
diff --git a/net-mgmt/net-snmp-devel/files/patch-parse.c b/net-mgmt/net-snmp-devel/files/patch-parse.c
new file mode 100644
index 000000000000..63eb1e023f19
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-parse.c
@@ -0,0 +1,12 @@
+--- snmplib/parse.c.orig Tue Jan 25 10:04:35 2005
++++ snmplib/parse.c Tue Jan 25 10:05:02 2005
+@@ -106,6 +106,9 @@
+ #if defined(HAVE_REGEX_H) && defined(HAVE_REGCOMP)
+ #include <regex.h>
+ #endif
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-scapi.c b/net-mgmt/net-snmp-devel/files/patch-scapi.c
new file mode 100644
index 000000000000..2d6711989e35
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-scapi.c
@@ -0,0 +1,12 @@
+--- snmplib/scapi.c.orig Tue Jan 25 10:18:44 2005
++++ snmplib/scapi.c Tue Jan 25 10:19:01 2005
+@@ -46,6 +46,9 @@
+ #include <netinet/in.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmpUDPDomain.c b/net-mgmt/net-snmp-devel/files/patch-snmpUDPDomain.c
new file mode 100644
index 000000000000..8ed548828d8c
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmpUDPDomain.c
@@ -0,0 +1,11 @@
+--- snmplib/snmpUDPDomain.c.orig Mon Jan 24 10:47:16 2005
++++ snmplib/snmpUDPDomain.c Mon Jan 24 10:47:41 2005
+@@ -88,7 +88,7 @@
+ } else {
+ char tmp[64];
+
+- sprintf(tmp, "UDP: [%s]:%hd",
++ sprintf(tmp, "UDP: [%s]:%hu",
+ inet_ntoa(to->sin_addr), ntohs(to->sin_port));
+ return strdup(tmp);
+ }
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmp_auth.c b/net-mgmt/net-snmp-devel/files/patch-snmp_auth.c
new file mode 100644
index 000000000000..be52a5e4fd36
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmp_auth.c
@@ -0,0 +1,12 @@
+--- snmplib/snmp_auth.c.orig Tue Jan 25 10:08:14 2005
++++ snmplib/snmp_auth.c Tue Jan 25 10:08:34 2005
+@@ -63,6 +63,9 @@
+ #include <arpa/inet.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmp_debug.c b/net-mgmt/net-snmp-devel/files/patch-snmp_debug.c
new file mode 100644
index 000000000000..6b24b5354b77
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmp_debug.c
@@ -0,0 +1,12 @@
+--- snmplib/snmp_debug.c.orig Tue Jan 25 10:10:49 2005
++++ snmplib/snmp_debug.c Tue Jan 25 10:11:06 2005
+@@ -22,6 +22,9 @@
+ #include <winsock.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmp_logging.c b/net-mgmt/net-snmp-devel/files/patch-snmp_logging.c
new file mode 100644
index 000000000000..f66b33d0dd6e
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmp_logging.c
@@ -0,0 +1,12 @@
+--- snmplib/snmp_logging.c.orig Tue Jan 25 10:14:41 2005
++++ snmplib/snmp_logging.c Tue Jan 25 10:15:05 2005
+@@ -65,6 +65,9 @@
+ #include <varargs.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmp_transport.c b/net-mgmt/net-snmp-devel/files/patch-snmp_transport.c
new file mode 100644
index 000000000000..e1ae87834fe9
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmp_transport.c
@@ -0,0 +1,12 @@
+--- snmplib/snmp_transport.c.orig Tue Jan 25 10:21:33 2005
++++ snmplib/snmp_transport.c Tue Jan 25 10:21:52 2005
+@@ -12,6 +12,9 @@
+ #include <stdlib.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmp_vars.c b/net-mgmt/net-snmp-devel/files/patch-snmp_vars.c
new file mode 100644
index 000000000000..5004187b2108
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-snmp_vars.c
@@ -0,0 +1,13 @@
+--- agent/snmp_vars.c.orig Mon Jan 24 09:12:09 2005
++++ agent/snmp_vars.c Mon Jan 24 09:12:23 2005
+@@ -136,10 +136,6 @@
+ #include <inet/mib2.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+ #include <net-snmp/agent/mib_modules.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-snmpusm.c b/net-mgmt/net-snmp-devel/files/patch-snmpusm.c
index 7b0ced219ae5..4eae56c1a0f0 100644
--- a/net-mgmt/net-snmp-devel/files/patch-snmpusm.c
+++ b/net-mgmt/net-snmp-devel/files/patch-snmpusm.c
@@ -1,6 +1,16 @@
---- snmplib/snmpusm.c.orig Wed Dec 8 19:32:52 2004
-+++ snmplib/snmpusm.c Wed Dec 8 19:33:30 2004
-@@ -89,6 +89,8 @@
+--- snmplib/snmpusm.c.orig Thu Sep 16 07:57:47 2004
++++ snmplib/snmpusm.c Tue Jan 25 10:23:02 2005
+@@ -54,6 +54,9 @@
+ #include <netinet/in.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif
+@@ -89,6 +92,8 @@
oid usmAESPrivProtocol[10] = { 1, 3, 6, 1, 6, 3, 10, 1, 2, 4 };
/* backwards compat */
oid *usmAES128PrivProtocol = usmAESPrivProtocol;
diff --git a/net-mgmt/net-snmp-devel/files/patch-subagent.c b/net-mgmt/net-snmp-devel/files/patch-subagent.c
new file mode 100644
index 000000000000..f198c4da7990
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-subagent.c
@@ -0,0 +1,13 @@
+--- agent/mibgroup/agentx/subagent.c.orig Mon Jan 24 09:17:08 2005
++++ agent/mibgroup/agentx/subagent.c Mon Jan 24 09:17:12 2005
+@@ -36,10 +36,6 @@
+ #include <netinet/in.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+ #include <net-snmp/library/snmp_assert.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-sysORTable.c b/net-mgmt/net-snmp-devel/files/patch-sysORTable.c
new file mode 100644
index 000000000000..e48aa29e5c86
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-sysORTable.c
@@ -0,0 +1,13 @@
+--- agent/mibgroup/mibII/sysORTable.c.orig Mon Jan 24 08:27:58 2005
++++ agent/mibgroup/mibII/sysORTable.c Mon Jan 24 08:28:10 2005
+@@ -34,10 +34,6 @@
+ #include <netinet/in.h>
+ #endif
+
+-#if HAVE_DMALLOC_H
+-#include <dmalloc.h>
+-#endif
+-
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+ #include <net-snmp/agent/agent_callbacks.h>
diff --git a/net-mgmt/net-snmp-devel/files/patch-tools.c b/net-mgmt/net-snmp-devel/files/patch-tools.c
new file mode 100644
index 000000000000..f24a401ec9e6
--- /dev/null
+++ b/net-mgmt/net-snmp-devel/files/patch-tools.c
@@ -0,0 +1,12 @@
+--- snmplib/tools.c.orig Tue Jan 25 10:13:50 2005
++++ snmplib/tools.c Tue Jan 25 10:14:06 2005
+@@ -44,6 +44,9 @@
+ #include <arpa/inet.h>
+ #endif
+
++#if HAVE_UNISTD_H
++#include <unistd.h>
++#endif
+ #if HAVE_DMALLOC_H
+ #include <dmalloc.h>
+ #endif