Changes 5.4.2: snmplib: - [PATCH 1921861]: Avoid endless loop after truncating 64bit int - Better handling of CONTAINER_INSERT failures with multiple indices snmpd: - [PATCH 2023633]: add SCTP-MIB implementation (Linux only) - suppress annoying "registration != duplicate" warning for root oids build: - [BUG 2023803]: Compilation problems on HP-UX 11.31 - Update to libtool 1.5.26 AIX: - Add support for AIX 6.x.diff -r1.72 -r1.73 pkgsrc/net/net-snmp/Makefile
(adam)
@@ -1,16 +1,16 @@ | @@ -1,16 +1,16 @@ | |||
1 | # $NetBSD: Makefile,v 1.72 2008/07/15 09:14:01 adam Exp $ | 1 | # $NetBSD: Makefile,v 1.73 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | DISTNAME= net-snmp-5.4.1.2 | 3 | DISTNAME= net-snmp-5.4.2 | |
4 | CATEGORIES= net | 4 | CATEGORIES= net | |
5 | MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=net-snmp/} | 5 | MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=net-snmp/} | |
6 | 6 | |||
7 | MAINTAINER= adam@NetBSD.org | 7 | MAINTAINER= adam@NetBSD.org | |
8 | HOMEPAGE= http://www.net-snmp.org/ | 8 | HOMEPAGE= http://www.net-snmp.org/ | |
9 | COMMENT= Extensible SNMP implementation | 9 | COMMENT= Extensible SNMP implementation | |
10 | 10 | |||
11 | CONFLICTS= ucd-snmp-[0-9]* | 11 | CONFLICTS= ucd-snmp-[0-9]* | |
12 | CONFLICTS+= nocol-[0-9]* # bin/snmpget bin/snmpwalk | 12 | CONFLICTS+= nocol-[0-9]* # bin/snmpget bin/snmpwalk | |
13 | 13 | |||
14 | USE_LIBTOOL= yes | 14 | USE_LIBTOOL= yes | |
15 | GNU_CONFIGURE= yes | 15 | GNU_CONFIGURE= yes | |
16 | 16 |
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | @comment $NetBSD: PLIST,v 1.17 2008/04/12 22:43:08 jlam Exp $ | 1 | @comment $NetBSD: PLIST,v 1.18 2008/09/08 12:58:09 adam Exp $ | |
2 | bin/encode_keychange | 2 | bin/encode_keychange | |
3 | bin/fixproc | 3 | bin/fixproc | |
4 | bin/ipf-mod.pl | 4 | bin/ipf-mod.pl | |
5 | bin/mib2c | 5 | bin/mib2c | |
6 | bin/mib2c-update | 6 | bin/mib2c-update | |
7 | bin/net-snmp-config | 7 | bin/net-snmp-config | |
8 | bin/snmpbulkget | 8 | bin/snmpbulkget | |
9 | bin/snmpbulkwalk | 9 | bin/snmpbulkwalk | |
10 | bin/snmpcheck | 10 | bin/snmpcheck | |
11 | bin/snmpconf | 11 | bin/snmpconf | |
12 | bin/snmpdelta | 12 | bin/snmpdelta | |
13 | bin/snmpdf | 13 | bin/snmpdf | |
14 | bin/snmpget | 14 | bin/snmpget | |
@@ -453,26 +453,27 @@ share/snmp/mib2c.check_values_local.conf | @@ -453,26 +453,27 @@ share/snmp/mib2c.check_values_local.conf | |||
453 | share/snmp/mib2c.column_defines.conf | 453 | share/snmp/mib2c.column_defines.conf | |
454 | share/snmp/mib2c.column_enums.conf | 454 | share/snmp/mib2c.column_enums.conf | |
455 | share/snmp/mib2c.column_storage.conf | 455 | share/snmp/mib2c.column_storage.conf | |
456 | share/snmp/mib2c.conf | 456 | share/snmp/mib2c.conf | |
457 | share/snmp/mib2c.container.conf | 457 | share/snmp/mib2c.container.conf | |
458 | share/snmp/mib2c.create-dataset.conf | 458 | share/snmp/mib2c.create-dataset.conf | |
459 | share/snmp/mib2c.genhtml.conf | 459 | share/snmp/mib2c.genhtml.conf | |
460 | share/snmp/mib2c.int_watch.conf | 460 | share/snmp/mib2c.int_watch.conf | |
461 | share/snmp/mib2c.iterate.conf | 461 | share/snmp/mib2c.iterate.conf | |
462 | share/snmp/mib2c.iterate_access.conf | 462 | share/snmp/mib2c.iterate_access.conf | |
463 | share/snmp/mib2c.mfd.conf | 463 | share/snmp/mib2c.mfd.conf | |
464 | share/snmp/mib2c.notify.conf | 464 | share/snmp/mib2c.notify.conf | |
465 | share/snmp/mib2c.old-api.conf | 465 | share/snmp/mib2c.old-api.conf | |
466 | share/snmp/mib2c.perl.conf | |||
466 | share/snmp/mib2c.scalar.conf | 467 | share/snmp/mib2c.scalar.conf | |
467 | share/snmp/mib2c.table_data.conf | 468 | share/snmp/mib2c.table_data.conf | |
468 | share/snmp/mibs/AGENTX-MIB.txt | 469 | share/snmp/mibs/AGENTX-MIB.txt | |
469 | share/snmp/mibs/DISMAN-EVENT-MIB.txt | 470 | share/snmp/mibs/DISMAN-EVENT-MIB.txt | |
470 | share/snmp/mibs/DISMAN-SCHEDULE-MIB.txt | 471 | share/snmp/mibs/DISMAN-SCHEDULE-MIB.txt | |
471 | share/snmp/mibs/DISMAN-SCRIPT-MIB.txt | 472 | share/snmp/mibs/DISMAN-SCRIPT-MIB.txt | |
472 | share/snmp/mibs/EtherLike-MIB.txt | 473 | share/snmp/mibs/EtherLike-MIB.txt | |
473 | share/snmp/mibs/HCNUM-TC.txt | 474 | share/snmp/mibs/HCNUM-TC.txt | |
474 | share/snmp/mibs/HOST-RESOURCES-MIB.txt | 475 | share/snmp/mibs/HOST-RESOURCES-MIB.txt | |
475 | share/snmp/mibs/HOST-RESOURCES-TYPES.txt | 476 | share/snmp/mibs/HOST-RESOURCES-TYPES.txt | |
476 | share/snmp/mibs/IANA-ADDRESS-FAMILY-NUMBERS-MIB.txt | 477 | share/snmp/mibs/IANA-ADDRESS-FAMILY-NUMBERS-MIB.txt | |
477 | share/snmp/mibs/IANA-LANGUAGE-MIB.txt | 478 | share/snmp/mibs/IANA-LANGUAGE-MIB.txt | |
478 | share/snmp/mibs/IANA-RTPROTO-MIB.txt | 479 | share/snmp/mibs/IANA-RTPROTO-MIB.txt | |
@@ -488,26 +489,27 @@ share/snmp/mibs/IPV6-TC.txt | @@ -488,26 +489,27 @@ share/snmp/mibs/IPV6-TC.txt | |||
488 | share/snmp/mibs/IPV6-TCP-MIB.txt | 489 | share/snmp/mibs/IPV6-TCP-MIB.txt | |
489 | share/snmp/mibs/IPV6-UDP-MIB.txt | 490 | share/snmp/mibs/IPV6-UDP-MIB.txt | |
490 | share/snmp/mibs/NET-SNMP-AGENT-MIB.txt | 491 | share/snmp/mibs/NET-SNMP-AGENT-MIB.txt | |
491 | share/snmp/mibs/NET-SNMP-EXAMPLES-MIB.txt | 492 | share/snmp/mibs/NET-SNMP-EXAMPLES-MIB.txt | |
492 | share/snmp/mibs/NET-SNMP-EXTEND-MIB.txt | 493 | share/snmp/mibs/NET-SNMP-EXTEND-MIB.txt | |
493 | share/snmp/mibs/NET-SNMP-MIB.txt | 494 | share/snmp/mibs/NET-SNMP-MIB.txt | |
494 | share/snmp/mibs/NET-SNMP-TC.txt | 495 | share/snmp/mibs/NET-SNMP-TC.txt | |
495 | share/snmp/mibs/NET-SNMP-VACM-MIB.txt | 496 | share/snmp/mibs/NET-SNMP-VACM-MIB.txt | |
496 | share/snmp/mibs/NOTIFICATION-LOG-MIB.txt | 497 | share/snmp/mibs/NOTIFICATION-LOG-MIB.txt | |
497 | share/snmp/mibs/RFC-1215.txt | 498 | share/snmp/mibs/RFC-1215.txt | |
498 | share/snmp/mibs/RFC1155-SMI.txt | 499 | share/snmp/mibs/RFC1155-SMI.txt | |
499 | share/snmp/mibs/RFC1213-MIB.txt | 500 | share/snmp/mibs/RFC1213-MIB.txt | |
500 | share/snmp/mibs/RMON-MIB.txt | 501 | share/snmp/mibs/RMON-MIB.txt | |
502 | share/snmp/mibs/SCTP-MIB.txt | |||
501 | share/snmp/mibs/SMUX-MIB.txt | 503 | share/snmp/mibs/SMUX-MIB.txt | |
502 | share/snmp/mibs/SNMP-COMMUNITY-MIB.txt | 504 | share/snmp/mibs/SNMP-COMMUNITY-MIB.txt | |
503 | share/snmp/mibs/SNMP-FRAMEWORK-MIB.txt | 505 | share/snmp/mibs/SNMP-FRAMEWORK-MIB.txt | |
504 | share/snmp/mibs/SNMP-MPD-MIB.txt | 506 | share/snmp/mibs/SNMP-MPD-MIB.txt | |
505 | share/snmp/mibs/SNMP-NOTIFICATION-MIB.txt | 507 | share/snmp/mibs/SNMP-NOTIFICATION-MIB.txt | |
506 | share/snmp/mibs/SNMP-PROXY-MIB.txt | 508 | share/snmp/mibs/SNMP-PROXY-MIB.txt | |
507 | share/snmp/mibs/SNMP-TARGET-MIB.txt | 509 | share/snmp/mibs/SNMP-TARGET-MIB.txt | |
508 | share/snmp/mibs/SNMP-USER-BASED-SM-MIB.txt | 510 | share/snmp/mibs/SNMP-USER-BASED-SM-MIB.txt | |
509 | share/snmp/mibs/SNMP-USM-AES-MIB.txt | 511 | share/snmp/mibs/SNMP-USM-AES-MIB.txt | |
510 | share/snmp/mibs/SNMP-USM-DH-OBJECTS-MIB.txt | 512 | share/snmp/mibs/SNMP-USM-DH-OBJECTS-MIB.txt | |
511 | share/snmp/mibs/SNMP-VIEW-BASED-ACM-MIB.txt | 513 | share/snmp/mibs/SNMP-VIEW-BASED-ACM-MIB.txt | |
512 | share/snmp/mibs/SNMPv2-CONF.txt | 514 | share/snmp/mibs/SNMPv2-CONF.txt | |
513 | share/snmp/mibs/SNMPv2-MIB.txt | 515 | share/snmp/mibs/SNMPv2-MIB.txt |
@@ -1,47 +1,42 @@ | @@ -1,47 +1,42 @@ | |||
1 | $NetBSD: distinfo,v 1.48 2008/07/15 09:14:01 adam Exp $ | 1 | $NetBSD: distinfo,v 1.49 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | SHA1 (net-snmp-5.4.1.2.tar.gz) = aebe7d881f26403abd6b9ef3e69565beb041138d | 3 | SHA1 (net-snmp-5.4.2.tar.gz) = 5b69da7d60bbc1092b61992f2d9ccb1051377ec6 | |
4 | RMD160 (net-snmp-5.4.1.2.tar.gz) = ef8870420b651bc83a72cd792308886aa8fbfe8f | 4 | RMD160 (net-snmp-5.4.2.tar.gz) = 8c0cfd259893023c2c98fa68746adb48555d7788 | |
5 | Size (net-snmp-5.4.1.2.tar.gz) = 5123346 bytes | 5 | Size (net-snmp-5.4.2.tar.gz) = 5168274 bytes | |
6 | SHA1 (patch-aa) = 51b09cc020776d136861d34f9ea529a986d2426d | 6 | SHA1 (patch-aa) = 34f85e513ace26c1c2b05bb1c4b72a23491861cf | |
7 | SHA1 (patch-ab) = 3227eeb8b54b37813d8b6949f8c6ddc446038bf2 | 7 | SHA1 (patch-ab) = 3227eeb8b54b37813d8b6949f8c6ddc446038bf2 | |
8 | SHA1 (patch-ac) = acdcde40ec53215d7778b2d0a67656b82274d006 | 8 | SHA1 (patch-ac) = becbd7d3f7bbd16d6ddd1a6ea5467a127553caa4 | |
9 | SHA1 (patch-ad) = 0041bbc3c1b2be73c8d1af1aba671d3a227473f4 | |||
10 | SHA1 (patch-ae) = 721e62bb42b6d3787f36316cf2628cd71ae6a6ce | 9 | SHA1 (patch-ae) = 721e62bb42b6d3787f36316cf2628cd71ae6a6ce | |
11 | SHA1 (patch-af) = 88d0433a6a233dc52fec10e29183d820c50bd524 | 10 | SHA1 (patch-af) = 15a18d1a8f3a8ffaba5facb37420668791944d29 | |
12 | SHA1 (patch-ag) = 7021f7238c37635c9c32ceca681fd42aa125437f | 11 | SHA1 (patch-ag) = 7021f7238c37635c9c32ceca681fd42aa125437f | |
13 | SHA1 (patch-ah) = 9ad04b5c0046a82c4e601e4f3abb2dd491846489 | 12 | SHA1 (patch-ah) = 9ad04b5c0046a82c4e601e4f3abb2dd491846489 | |
14 | SHA1 (patch-ai) = c57baca06856187115db39fd50668203dad0a94c | 13 | SHA1 (patch-ai) = c57baca06856187115db39fd50668203dad0a94c | |
15 | SHA1 (patch-aj) = 30c28c4801cea33d54e68bbde603e7d531dfb2f8 | 14 | SHA1 (patch-aj) = 30c28c4801cea33d54e68bbde603e7d531dfb2f8 | |
16 | SHA1 (patch-ak) = cccad21d4f56e79799a433ef7bf0e8ff4e917afb | 15 | SHA1 (patch-ak) = cccad21d4f56e79799a433ef7bf0e8ff4e917afb | |
17 | SHA1 (patch-al) = 2609e273d557e1ce06c1295d86965fe26ac7ff08 | 16 | SHA1 (patch-al) = 2609e273d557e1ce06c1295d86965fe26ac7ff08 | |
18 | SHA1 (patch-am) = 58c2439ac2ad96e4114bc454d8148abd9dde4d43 | 17 | SHA1 (patch-am) = 84fc1131fb2699ab45b161a07017253e23a8ad08 | |
19 | SHA1 (patch-an) = 167f23c62c085efc96a25bc2be5dca3c746dde6f | 18 | SHA1 (patch-an) = 167f23c62c085efc96a25bc2be5dca3c746dde6f | |
20 | SHA1 (patch-da) = 7466445c8388492344acdee236b153cb5f5b45e1 | 19 | SHA1 (patch-da) = 7466445c8388492344acdee236b153cb5f5b45e1 | |
21 | SHA1 (patch-db) = bec0bee1860ee42ba64b4c07df2280e206eaf582 | 20 | SHA1 (patch-db) = bec0bee1860ee42ba64b4c07df2280e206eaf582 | |
22 | SHA1 (patch-dc) = a60caa72af001f5bbda173e5daa9afc6a7180a60 | 21 | SHA1 (patch-dc) = 3f668032cbef42b44ee908b3c973af619ce0a689 | |
23 | SHA1 (patch-dd) = 08da0d1da485959549ac461e5cbb7030f800e643 | 22 | SHA1 (patch-dd) = 08da0d1da485959549ac461e5cbb7030f800e643 | |
24 | SHA1 (patch-de) = b505cef8542b30b3d28f5b3e61c473076e242d24 | 23 | SHA1 (patch-de) = b505cef8542b30b3d28f5b3e61c473076e242d24 | |
25 | SHA1 (patch-dg) = 6e6e396add0613dd76e3b8618008a7ebf8103c7c | 24 | SHA1 (patch-dg) = 6e6e396add0613dd76e3b8618008a7ebf8103c7c | |
26 | SHA1 (patch-dh) = c9a776d6574df008adae52a2f08930e0662f70b3 | 25 | SHA1 (patch-dh) = c9a776d6574df008adae52a2f08930e0662f70b3 | |
27 | SHA1 (patch-di) = e0e1039c1adbf10ae56c50998ff74b39193e7348 | 26 | SHA1 (patch-di) = e0e1039c1adbf10ae56c50998ff74b39193e7348 | |
28 | SHA1 (patch-dl) = e464597dcade165978cea80a51d66bbb8d19e4db | 27 | SHA1 (patch-dl) = e464597dcade165978cea80a51d66bbb8d19e4db | |
29 | SHA1 (patch-dm) = 05c182f5bc1751ea0a0bcc7e21f24684b3c4933a | 28 | SHA1 (patch-dm) = 05c182f5bc1751ea0a0bcc7e21f24684b3c4933a | |
30 | SHA1 (patch-dn) = 16c68c667c129c4fcccdbff704d7d25481691710 | 29 | SHA1 (patch-dn) = b0c40b7dc7311c446016750cf3bb6e42e1aef9be | |
31 | SHA1 (patch-do) = 7a69e6e81cbddbb7fc610f4260fe521a5e4c2348 | 30 | SHA1 (patch-do) = 7a69e6e81cbddbb7fc610f4260fe521a5e4c2348 | |
32 | SHA1 (patch-dp) = 3ecdfa78a5c7a86715d3fd3ab8bbd0208a0d685d | 31 | SHA1 (patch-dp) = 3ecdfa78a5c7a86715d3fd3ab8bbd0208a0d685d | |
33 | SHA1 (patch-dq) = 619d94d9937098b684ee8d0f1a3a92dfdff2155c | 32 | SHA1 (patch-dq) = 619d94d9937098b684ee8d0f1a3a92dfdff2155c | |
34 | SHA1 (patch-dr) = ab75e5cf3448d9c0520b6e7d2c68adfbf3ab639b | 33 | SHA1 (patch-dr) = 9f962834da29776f43ee1483aca00625bb58674b | |
35 | SHA1 (patch-ds) = 4d59f016eca12660f94dcba89f94e395323ab7b4 | 34 | SHA1 (patch-ds) = 0ce73a2d5b5b4b9629b7e49e9d4e655ec0f89055 | |
36 | SHA1 (patch-dt) = bd1884af6fb3743e79ab926fcd952068cb9a3642 | 35 | SHA1 (patch-dt) = bd1884af6fb3743e79ab926fcd952068cb9a3642 | |
37 | SHA1 (patch-du) = a07160ee1197d8aefa3ccaf7fb255be48311e8bc | 36 | SHA1 (patch-du) = c3c053c95c24c3fecfdcb7dfe649168a866206ba | |
38 | SHA1 (patch-ea) = 9d8d6b167b87d7e4f184b06f1279a55072a7645e | |||
39 | SHA1 (patch-ee) = ec2a41ba9489bf71412169c0f8367eac214e3738 | |||
40 | SHA1 (patch-eg) = 421ccf1c810a2b03d7ff10fe38e8a3eea62d9836 | 37 | SHA1 (patch-eg) = 421ccf1c810a2b03d7ff10fe38e8a3eea62d9836 | |
41 | SHA1 (patch-eh) = c2dbd651a0fcf6e20b8a9eee68f0ab30763af912 | 38 | SHA1 (patch-eh) = c2dbd651a0fcf6e20b8a9eee68f0ab30763af912 | |
42 | SHA1 (patch-ei) = 7eb4899b08b73c79f1eb8616bcebad38c0fbe148 | 39 | SHA1 (patch-ei) = 7eb4899b08b73c79f1eb8616bcebad38c0fbe148 | |
43 | SHA1 (patch-ej) = c8047a6109bf6b833c56562d48b56b480c4299be | |||
44 | SHA1 (patch-el) = f80dc7058b8a60e3be53e5673538f6eb2d173b68 | 40 | SHA1 (patch-el) = f80dc7058b8a60e3be53e5673538f6eb2d173b68 | |
45 | SHA1 (patch-ep) = 91029b17538360ba09e8e74943d2c4481f89a33a | 41 | SHA1 (patch-ep) = 91029b17538360ba09e8e74943d2c4481f89a33a | |
46 | SHA1 (patch-es) = c26c048ccbda7e4d28cb0a2263cdaa71befb4f96 | 42 | SHA1 (patch-es) = c26c048ccbda7e4d28cb0a2263cdaa71befb4f96 | |
47 | SHA1 (patch-et) = 63e31a08413b004608540a28a8fc448966320e7f |
@@ -1,16 +1,16 @@ | @@ -1,16 +1,16 @@ | |||
1 | $NetBSD: patch-aa,v 1.7 2007/08/10 23:37:02 seb Exp $ | 1 | $NetBSD: patch-aa,v 1.8 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/host/hr_filesys.c.orig 2006-08-06 00:01:01.000000000 +0000 | 3 | --- agent/mibgroup/host/hr_filesys.c.orig 2008-07-30 11:58:30.000000000 +0200 | |
4 | +++ agent/mibgroup/host/hr_filesys.c | 4 | +++ agent/mibgroup/host/hr_filesys.c | |
5 | @@ -93,6 +93,11 @@ struct mnttab *HRFS_entry = &HRFS_entry | 5 | @@ -96,6 +96,11 @@ struct mnttab *HRFS_entry = &HRFS_entry | |
6 | 6 | |||
7 | #elif defined(HAVE_STATVFS) && defined(__NetBSD__) | 7 | #elif defined(HAVE_STATVFS) && defined(__NetBSD__) | |
8 | 8 | |||
9 | +#if !defined(MFSNAMELEN) && defined(_VFS_NAMELEN) | 9 | +#if !defined(MFSNAMELEN) && defined(_VFS_NAMELEN) | |
10 | +#define MFSNAMELEN _VFS_NAMELEN | 10 | +#define MFSNAMELEN _VFS_NAMELEN | |
11 | +#endif | 11 | +#endif | |
12 | + | 12 | + | |
13 | +#define getfsstat getvfsstat | 13 | +#define getfsstat getvfsstat | |
14 | static struct statvfs *fsstats = NULL; | 14 | static struct statvfs *fsstats = NULL; | |
15 | struct statvfs *HRFS_entry; | 15 | struct statvfs *HRFS_entry; | |
16 | static int fscount; | 16 | static int fscount; |
@@ -1,126 +1,136 @@ | @@ -1,126 +1,136 @@ | |||
1 | $NetBSD: patch-ac,v 1.6 2007/08/11 11:05:56 adam Exp $ | 1 | $NetBSD: patch-ac,v 1.7 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- configure.in.orig 2007-08-11 12:17:24.000000000 +0200 | 3 | --- configure.in.orig 2008-09-05 11:27:25.000000000 +0200 | |
4 | +++ configure.in | 4 | +++ configure.in | |
5 | @@ -2678,6 +2678,8 @@ AC_CHECK_LIB(kstat, kstat_lookup, | 5 | @@ -2697,6 +2697,8 @@ AC_CHECK_LIB(kstat, kstat_lookup, | |
6 | AC_DEFINE(HAVE_LIBKSTAT, 1, [Define to 1 if you have the `kstat' library (-lkstat).]) | 6 | AC_DEFINE(HAVE_LIBKSTAT, 1, [Define to 1 if you have the `kstat' library (-lkstat).]) | |
7 | LNETSNMPLIBS="${LNETSNMPLIBS} -lkstat") | 7 | LNETSNMPLIBS="${LNETSNMPLIBS} -lkstat") | |
8 | 8 | |||
9 | +AC_CHECK_LIB(des, des_cbc_encrypt) | 9 | +AC_CHECK_LIB(des, des_cbc_encrypt) | |
10 | + | 10 | + | |
11 | # Check for libraries that the agent needs | 11 | # Check for libraries that the agent needs | |
12 | # saving old libraries | 12 | # saving old libraries | |
13 | NONAGENTLIBS=$LIBS | 13 | NONAGENTLIBS=$LIBS | |
14 | @@ -3406,6 +3408,12 @@ AC_CHECK_HEADERS(netinet/ip6.h netinet6/ | 14 | @@ -3425,6 +3427,12 @@ AC_CHECK_HEADERS(netinet/ip6.h netinet6/ | |
15 | #if HAVE_NETINET_IP6_H | 15 | #if HAVE_NETINET_IP6_H | |
16 | #include <netinet/ip6.h> | 16 | #include <netinet/ip6.h> | |
17 | #endif | 17 | #endif | |
18 | +#if HAVE_NET_IF_H | 18 | +#if HAVE_NET_IF_H | |
19 | +#include <net/if.h> | 19 | +#include <net/if.h> | |
20 | +#endif | 20 | +#endif | |
21 | +#if HAVE_NET_ROUTE_H | 21 | +#if HAVE_NET_ROUTE_H | |
22 | +#include <net/route.h> | 22 | +#include <net/route.h> | |
23 | +#endif | 23 | +#endif | |
24 | ]]) | 24 | ]]) | |
25 | # DYNAMIC MODULE SUPPORT | 25 | # DYNAMIC MODULE SUPPORT | |
26 | AC_CHECK_HEADERS(dlfcn.h) | 26 | AC_CHECK_HEADERS(dlfcn.h) | |
27 | @@ -3800,7 +3808,9 @@ AC_CHECK_STRUCT_FOR([ | 27 | @@ -3864,8 +3872,10 @@ AC_CHECK_STRUCT_FOR([ | |
28 | #endif | |||
29 | #include <sys/types.h> | 28 | #include <sys/types.h> | |
29 | #ifdef IFNET_NEEDS_KERNEL | |||
30 | #define KERNEL | 30 | #define KERNEL | |
31 | +#if !defined(__DragonFly__) | 31 | +#if !defined(__DragonFly__) | |
32 | #define _KERNEL | 32 | #define _KERNEL | |
33 | #endif | |||
33 | +#endif | 34 | +#endif | |
34 | #include <sys/socket.h> | 35 | #include <sys/socket.h> | |
35 | #undef KERNEL | 36 | ], sockaddr, sa_len, no) | |
36 | #undef _KERNEL | 37 | ||
37 | @@ -3812,7 +3822,9 @@ AC_CHECK_STRUCT_FOR([ | 38 | @@ -3876,8 +3886,10 @@ AC_CHECK_STRUCT_FOR([ | |
38 | #endif | |||
39 | #include <sys/types.h> | 39 | #include <sys/types.h> | |
40 | #ifdef IFNET_NEEDS_KERNEL | |||
40 | #define KERNEL | 41 | #define KERNEL | |
41 | +#if !defined(__DragonFly__) | 42 | +#if !defined(__DragonFly__) | |
42 | #define _KERNEL | 43 | #define _KERNEL | |
44 | #endif | |||
43 | +#endif | 45 | +#endif | |
44 | #include <sys/socket.h> | 46 | #include <sys/socket.h> | |
45 | #undef KERNEL | 47 | ], sockaddr, sa_union.sa_generic.sa_family2, no) | |
46 | #undef _KERNEL | 48 | ||
47 | @@ -3848,7 +3860,9 @@ AC_CHECK_STRUCT_FOR([ | 49 | @@ -3912,8 +3924,10 @@ AC_CHECK_STRUCT_FOR([ | |
48 | #endif | |||
49 | #include <sys/types.h> | 50 | #include <sys/types.h> | |
51 | #ifdef IFNET_NEEDS_KERNEL | |||
50 | #define KERNEL | 52 | #define KERNEL | |
51 | +#if !defined(__DragonFly__) | 53 | +#if !defined(__DragonFly__) | |
52 | #define _KERNEL | 54 | #define _KERNEL | |
55 | #endif | |||
53 | +#endif | 56 | +#endif | |
54 | #include <sys/socket.h> | 57 | #include <sys/socket.h> | |
55 | #undef KERNEL | 58 | #undef KERNEL | |
56 | #undef _KERNEL | 59 | #undef _KERNEL | |
57 | @@ -3866,7 +3880,9 @@ AC_TRY_COMPILE([ | 60 | @@ -3932,8 +3946,10 @@ AC_TRY_COMPILE([ | |
58 | #endif | |||
59 | #include <sys/types.h> | 61 | #include <sys/types.h> | |
62 | #ifdef IFNET_NEEDS_KERNEL | |||
60 | #define KERNEL | 63 | #define KERNEL | |
61 | +#if !defined(__DragonFly__) | 64 | +#if !defined(__DragonFly__) | |
62 | #define _KERNEL | 65 | #define _KERNEL | |
66 | #endif | |||
63 | +#endif | 67 | +#endif | |
64 | #include <sys/socket.h> | 68 | #include <sys/socket.h> | |
65 | #undef KERNEL | 69 | #undef KERNEL | |
66 | #undef _KERNEL | 70 | #undef _KERNEL | |
67 | @@ -3890,7 +3906,9 @@ AC_TRY_COMPILE([ | 71 | @@ -3958,8 +3974,10 @@ AC_TRY_COMPILE([ | |
68 | #endif | |||
69 | #include <sys/types.h> | 72 | #include <sys/types.h> | |
73 | #ifdef IFNET_NEEDS_KERNEL | |||
70 | #define KERNEL | 74 | #define KERNEL | |
71 | +#if !defined(__DragonFly__) | 75 | +#if !defined(__DragonFly__) | |
72 | #define _KERNEL | 76 | #define _KERNEL | |
77 | #endif | |||
73 | +#endif | 78 | +#endif | |
74 | #include <sys/socket.h> | 79 | #include <sys/socket.h> | |
75 | #undef KERNEL | 80 | #undef KERNEL | |
76 | #undef _KERNEL | 81 | #undef _KERNEL | |
77 | @@ -3947,7 +3965,9 @@ AC_TRY_COMPILE([ | 82 | @@ -4017,8 +4035,10 @@ AC_TRY_COMPILE([ | |
78 | #endif | |||
79 | #include <sys/types.h> | 83 | #include <sys/types.h> | |
84 | #ifdef IFNET_NEEDS_KERNEL | |||
80 | #define KERNEL | 85 | #define KERNEL | |
81 | +#if !defined(__DragonFly__) | 86 | +#if !defined(__DragonFly__) | |
82 | #define _KERNEL | 87 | #define _KERNEL | |
88 | #endif | |||
83 | +#endif | 89 | +#endif | |
84 | #include <sys/socket.h> | 90 | #include <sys/socket.h> | |
85 | #undef KERNEL | 91 | #undef KERNEL | |
86 | #undef _KERNEL | 92 | #undef _KERNEL | |
87 | @@ -3985,7 +4005,9 @@ AC_CHECK_STRUCT_FOR([ | 93 | @@ -4057,8 +4077,10 @@ AC_CHECK_STRUCT_FOR([ | |
88 | #endif | |||
89 | #include <sys/types.h> | 94 | #include <sys/types.h> | |
95 | #ifdef IFNET_NEEDS_KERNEL | |||
90 | #define KERNEL | 96 | #define KERNEL | |
91 | +#if !defined(__DragonFly__) | 97 | +#if !defined(__DragonFly__) | |
92 | #define _KERNEL | 98 | #define _KERNEL | |
99 | #endif | |||
93 | +#endif | 100 | +#endif | |
94 | #include <sys/socket.h> | 101 | #include <sys/socket.h> | |
95 | #undef KERNEL | 102 | #undef KERNEL | |
96 | #undef _KERNEL | 103 | #undef _KERNEL | |
97 | @@ -3998,7 +4020,9 @@ AC_CHECK_STRUCT_FOR([ | 104 | @@ -4072,8 +4094,10 @@ AC_CHECK_STRUCT_FOR([ | |
98 | #endif | |||
99 | #include <sys/types.h> | 105 | #include <sys/types.h> | |
106 | #ifdef IFNET_NEEDS_KERNEL | |||
100 | #define KERNEL | 107 | #define KERNEL | |
101 | +#if !defined(__DragonFly__) | 108 | +#if !defined(__DragonFly__) | |
102 | #define _KERNEL | 109 | #define _KERNEL | |
110 | #endif | |||
103 | +#endif | 111 | +#endif | |
104 | #include <sys/socket.h> | 112 | #include <sys/socket.h> | |
105 | #undef KERNEL | 113 | #undef KERNEL | |
106 | #undef _KERNEL | 114 | #undef _KERNEL | |
107 | @@ -4011,7 +4035,9 @@ AC_CHECK_STRUCT_FOR([ | 115 | @@ -4087,8 +4111,10 @@ AC_CHECK_STRUCT_FOR([ | |
108 | #endif | |||
109 | #include <sys/types.h> | 116 | #include <sys/types.h> | |
117 | #ifdef IFNET_NEEDS_KERNEL | |||
110 | #define KERNEL | 118 | #define KERNEL | |
111 | +#if !defined(__DragonFly__) | 119 | +#if !defined(__DragonFly__) | |
112 | #define _KERNEL | 120 | #define _KERNEL | |
121 | #endif | |||
113 | +#endif | 122 | +#endif | |
114 | #include <sys/socket.h> | 123 | #include <sys/socket.h> | |
115 | #undef KERNEL | 124 | #undef KERNEL | |
116 | #undef _KERNEL | 125 | #undef _KERNEL | |
117 | @@ -4024,7 +4050,9 @@ AC_CHECK_STRUCT_FOR([ | 126 | @@ -4102,8 +4128,10 @@ AC_CHECK_STRUCT_FOR([ | |
118 | #endif | |||
119 | #include <sys/types.h> | 127 | #include <sys/types.h> | |
128 | #ifdef IFNET_NEEDS_KERNEL | |||
120 | #define KERNEL | 129 | #define KERNEL | |
121 | +#if !defined(__DragonFly__) | 130 | +#if !defined(__DragonFly__) | |
122 | #define _KERNEL | 131 | #define _KERNEL | |
132 | #endif | |||
123 | +#endif | 133 | +#endif | |
124 | #include <sys/socket.h> | 134 | #include <sys/socket.h> | |
125 | #undef KERNEL | 135 | #undef KERNEL | |
126 | #undef _KERNEL | 136 | #undef _KERNEL |
@@ -1,18 +1,18 @@ | @@ -1,18 +1,18 @@ | |||
1 | $NetBSD: patch-af,v 1.11 2007/08/11 11:05:56 adam Exp $ | 1 | $NetBSD: patch-af,v 1.12 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- configure.orig 2007-08-11 12:20:35.000000000 +0200 | 3 | --- configure.orig 2008-09-05 11:29:01.000000000 +0200 | |
4 | +++ configure | 4 | +++ configure | |
5 | @@ -27463,6 +27463,81 @@ _ACEOF | 5 | @@ -27854,6 +27854,81 @@ _ACEOF | |
6 | fi | 6 | fi | |
7 | 7 | |||
8 | 8 | |||
9 | + | 9 | + | |
10 | +echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5 | 10 | +echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5 | |
11 | +echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6 | 11 | +echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6 | |
12 | +if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then | 12 | +if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then | |
13 | + echo $ECHO_N "(cached) $ECHO_C" >&6 | 13 | + echo $ECHO_N "(cached) $ECHO_C" >&6 | |
14 | +else | 14 | +else | |
15 | + ac_check_lib_save_LIBS=$LIBS | 15 | + ac_check_lib_save_LIBS=$LIBS | |
16 | +LIBS="-ldes $LIBS" | 16 | +LIBS="-ldes $LIBS" | |
17 | +cat >conftest.$ac_ext <<_ACEOF | 17 | +cat >conftest.$ac_ext <<_ACEOF | |
18 | +/* confdefs.h. */ | 18 | +/* confdefs.h. */ | |
@@ -74,126 +74,136 @@ $NetBSD: patch-af,v 1.11 2007/08/11 11:0 | @@ -74,126 +74,136 @@ $NetBSD: patch-af,v 1.11 2007/08/11 11:0 | |||
74 | +if test $ac_cv_lib_des_des_cbc_encrypt = yes; then | 74 | +if test $ac_cv_lib_des_des_cbc_encrypt = yes; then | |
75 | + cat >>confdefs.h <<_ACEOF | 75 | + cat >>confdefs.h <<_ACEOF | |
76 | +#define HAVE_LIBDES 1 | 76 | +#define HAVE_LIBDES 1 | |
77 | +_ACEOF | 77 | +_ACEOF | |
78 | + | 78 | + | |
79 | + LIBS="-ldes $LIBS" | 79 | + LIBS="-ldes $LIBS" | |
80 | + | 80 | + | |
81 | +fi | 81 | +fi | |
82 | + | 82 | + | |
83 | + | 83 | + | |
84 | # Check for libraries that the agent needs | 84 | # Check for libraries that the agent needs | |
85 | # saving old libraries | 85 | # saving old libraries | |
86 | NONAGENTLIBS=$LIBS | 86 | NONAGENTLIBS=$LIBS | |
87 | @@ -36453,6 +36528,12 @@ cat >>conftest.$ac_ext <<_ACEOF | 87 | @@ -36844,6 +36919,12 @@ cat >>conftest.$ac_ext <<_ACEOF | |
88 | #if HAVE_NETINET_IP6_H | 88 | #if HAVE_NETINET_IP6_H | |
89 | #include <netinet/ip6.h> | 89 | #include <netinet/ip6.h> | |
90 | #endif | 90 | #endif | |
91 | +#if HAVE_NET_IF_H | 91 | +#if HAVE_NET_IF_H | |
92 | +#include <net/if.h> | 92 | +#include <net/if.h> | |
93 | +#endif | 93 | +#endif | |
94 | +#if HAVE_NET_ROUTE_H | 94 | +#if HAVE_NET_ROUTE_H | |
95 | +#include <net/route.h> | 95 | +#include <net/route.h> | |
96 | +#endif | 96 | +#endif | |
97 | 97 | |||
98 | 98 | |||
99 | #include <$ac_header> | 99 | #include <$ac_header> | |
100 | @@ -42273,7 +42354,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 100 | @@ -42849,8 +42930,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
101 | #endif | |||
102 | #include <sys/types.h> | 101 | #include <sys/types.h> | |
102 | #ifdef IFNET_NEEDS_KERNEL | |||
103 | #define KERNEL | 103 | #define KERNEL | |
104 | +#if !defined(__DragonFly__) | 104 | +#if !defined(__DragonFly__) | |
105 | #define _KERNEL | 105 | #define _KERNEL | |
106 | #endif | |||
106 | +#endif | 107 | +#endif | |
107 | #include <sys/socket.h> | 108 | #include <sys/socket.h> | |
108 | #undef KERNEL | 109 | ||
109 | #undef _KERNEL | 110 | ||
110 | @@ -42371,7 +42454,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 111 | @@ -42947,8 +43030,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
111 | #endif | |||
112 | #include <sys/types.h> | 112 | #include <sys/types.h> | |
113 | #ifdef IFNET_NEEDS_KERNEL | |||
113 | #define KERNEL | 114 | #define KERNEL | |
114 | +#if !defined(__DragonFly__) | 115 | +#if !defined(__DragonFly__) | |
115 | #define _KERNEL | 116 | #define _KERNEL | |
117 | #endif | |||
116 | +#endif | 118 | +#endif | |
117 | #include <sys/socket.h> | 119 | #include <sys/socket.h> | |
118 | #undef KERNEL | 120 | ||
119 | #undef _KERNEL | 121 | ||
120 | @@ -42665,7 +42750,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 122 | @@ -43241,8 +43326,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
121 | #endif | |||
122 | #include <sys/types.h> | 123 | #include <sys/types.h> | |
124 | #ifdef IFNET_NEEDS_KERNEL | |||
123 | #define KERNEL | 125 | #define KERNEL | |
124 | +#if !defined(__DragonFly__) | 126 | +#if !defined(__DragonFly__) | |
125 | #define _KERNEL | 127 | #define _KERNEL | |
128 | #endif | |||
126 | +#endif | 129 | +#endif | |
127 | #include <sys/socket.h> | 130 | #include <sys/socket.h> | |
128 | #undef KERNEL | 131 | #undef KERNEL | |
129 | #undef _KERNEL | 132 | #undef _KERNEL | |
130 | @@ -42752,7 +42839,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 133 | @@ -43330,8 +43417,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
131 | #endif | |||
132 | #include <sys/types.h> | 134 | #include <sys/types.h> | |
135 | #ifdef IFNET_NEEDS_KERNEL | |||
133 | #define KERNEL | 136 | #define KERNEL | |
134 | +#if !defined(__DragonFly__) | 137 | +#if !defined(__DragonFly__) | |
135 | #define _KERNEL | 138 | #define _KERNEL | |
139 | #endif | |||
136 | +#endif | 140 | +#endif | |
137 | #include <sys/socket.h> | 141 | #include <sys/socket.h> | |
138 | #undef KERNEL | 142 | #undef KERNEL | |
139 | #undef _KERNEL | 143 | #undef _KERNEL | |
140 | @@ -42819,7 +42908,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 144 | @@ -43399,8 +43488,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
141 | #endif | |||
142 | #include <sys/types.h> | 145 | #include <sys/types.h> | |
146 | #ifdef IFNET_NEEDS_KERNEL | |||
143 | #define KERNEL | 147 | #define KERNEL | |
144 | +#if !defined(__DragonFly__) | 148 | +#if !defined(__DragonFly__) | |
145 | #define _KERNEL | 149 | #define _KERNEL | |
150 | #endif | |||
146 | +#endif | 151 | +#endif | |
147 | #include <sys/socket.h> | 152 | #include <sys/socket.h> | |
148 | #undef KERNEL | 153 | #undef KERNEL | |
149 | #undef _KERNEL | 154 | #undef _KERNEL | |
150 | @@ -42957,7 +43048,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 155 | @@ -43539,8 +43630,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
151 | #endif | |||
152 | #include <sys/types.h> | 156 | #include <sys/types.h> | |
157 | #ifdef IFNET_NEEDS_KERNEL | |||
153 | #define KERNEL | 158 | #define KERNEL | |
154 | +#if !defined(__DragonFly__) | 159 | +#if !defined(__DragonFly__) | |
155 | #define _KERNEL | 160 | #define _KERNEL | |
161 | #endif | |||
156 | +#endif | 162 | +#endif | |
157 | #include <sys/socket.h> | 163 | #include <sys/socket.h> | |
158 | #undef KERNEL | 164 | #undef KERNEL | |
159 | #undef _KERNEL | 165 | #undef _KERNEL | |
160 | @@ -43188,7 +43281,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 166 | @@ -43772,8 +43865,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
161 | #endif | |||
162 | #include <sys/types.h> | 167 | #include <sys/types.h> | |
168 | #ifdef IFNET_NEEDS_KERNEL | |||
163 | #define KERNEL | 169 | #define KERNEL | |
164 | +#if !defined(__DragonFly__) | 170 | +#if !defined(__DragonFly__) | |
165 | #define _KERNEL | 171 | #define _KERNEL | |
172 | #endif | |||
166 | +#endif | 173 | +#endif | |
167 | #include <sys/socket.h> | 174 | #include <sys/socket.h> | |
168 | #undef KERNEL | 175 | #undef KERNEL | |
169 | #undef _KERNEL | 176 | #undef _KERNEL | |
170 | @@ -43287,7 +43382,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 177 | @@ -43873,8 +43968,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
171 | #endif | |||
172 | #include <sys/types.h> | 178 | #include <sys/types.h> | |
179 | #ifdef IFNET_NEEDS_KERNEL | |||
173 | #define KERNEL | 180 | #define KERNEL | |
174 | +#if !defined(__DragonFly__) | 181 | +#if !defined(__DragonFly__) | |
175 | #define _KERNEL | 182 | #define _KERNEL | |
183 | #endif | |||
176 | +#endif | 184 | +#endif | |
177 | #include <sys/socket.h> | 185 | #include <sys/socket.h> | |
178 | #undef KERNEL | 186 | #undef KERNEL | |
179 | #undef _KERNEL | 187 | #undef _KERNEL | |
180 | @@ -43386,7 +43483,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 188 | @@ -43974,8 +44071,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
181 | #endif | |||
182 | #include <sys/types.h> | 189 | #include <sys/types.h> | |
190 | #ifdef IFNET_NEEDS_KERNEL | |||
183 | #define KERNEL | 191 | #define KERNEL | |
184 | +#if !defined(__DragonFly__) | 192 | +#if !defined(__DragonFly__) | |
185 | #define _KERNEL | 193 | #define _KERNEL | |
194 | #endif | |||
186 | +#endif | 195 | +#endif | |
187 | #include <sys/socket.h> | 196 | #include <sys/socket.h> | |
188 | #undef KERNEL | 197 | #undef KERNEL | |
189 | #undef _KERNEL | 198 | #undef _KERNEL | |
190 | @@ -43485,7 +43584,9 @@ cat >>conftest.$ac_ext <<_ACEOF | 199 | @@ -44075,8 +44174,10 @@ cat >>conftest.$ac_ext <<_ACEOF | |
191 | #endif | |||
192 | #include <sys/types.h> | 200 | #include <sys/types.h> | |
201 | #ifdef IFNET_NEEDS_KERNEL | |||
193 | #define KERNEL | 202 | #define KERNEL | |
194 | +#if !defined(__DragonFly__) | 203 | +#if !defined(__DragonFly__) | |
195 | #define _KERNEL | 204 | #define _KERNEL | |
205 | #endif | |||
196 | +#endif | 206 | +#endif | |
197 | #include <sys/socket.h> | 207 | #include <sys/socket.h> | |
198 | #undef KERNEL | 208 | #undef KERNEL | |
199 | #undef _KERNEL | 209 | #undef _KERNEL |
@@ -1,83 +1,83 @@ | @@ -1,83 +1,83 @@ | |||
1 | $NetBSD: patch-am,v 1.8 2008/07/15 09:14:01 adam Exp $ | 1 | $NetBSD: patch-am,v 1.9 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/host/hr_swrun.c.orig 2007-04-02 16:51:34 +0300 | 3 | --- agent/mibgroup/host/hr_swrun.c.orig 2008-08-22 02:18:50.000000000 +0200 | |
4 | +++ agent/mibgroup/host/hr_swrun.c 2007-09-12 21:41:48 +0300 | 4 | +++ agent/mibgroup/host/hr_swrun.c | |
5 | @@ -599,6 +599,8 @@ | 5 | @@ -599,6 +599,8 @@ var_hrswrun(struct variable * vp, | |
6 | #elif HAVE_KVM_GETPROCS | 6 | #elif HAVE_KVM_GETPROCS | |
7 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | 7 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | |
8 | strcpy(string, proc_table[LowProcIndex].ki_comm); | 8 | strcpy(string, proc_table[LowProcIndex].ki_comm); | |
9 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 9 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
10 | + strcpy(string, proc_table[LowProcIndex].kp_comm); | 10 | + strcpy(string, proc_table[LowProcIndex].kp_comm); | |
11 | #else | 11 | #else | |
12 | strcpy(string, proc_table[LowProcIndex].kp_proc.p_comm); | 12 | strcpy(string, proc_table[LowProcIndex].kp_proc.p_comm); | |
13 | #endif | 13 | #endif | |
14 | @@ -722,6 +724,8 @@ | 14 | @@ -722,6 +724,8 @@ var_hrswrun(struct variable * vp, | |
15 | #elif HAVE_KVM_GETPROCS | 15 | #elif HAVE_KVM_GETPROCS | |
16 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | 16 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | |
17 | strcpy(string, proc_table[LowProcIndex].ki_comm); | 17 | strcpy(string, proc_table[LowProcIndex].ki_comm); | |
18 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 18 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
19 | + strcpy(string, proc_table[LowProcIndex].kp_comm); | 19 | + strcpy(string, proc_table[LowProcIndex].kp_comm); | |
20 | #else | 20 | #else | |
21 | strcpy(string, proc_table[LowProcIndex].kp_proc.p_comm); | 21 | strcpy(string, proc_table[LowProcIndex].kp_proc.p_comm); | |
22 | #endif | 22 | #endif | |
23 | @@ -921,11 +925,17 @@ | 23 | @@ -929,11 +933,17 @@ var_hrswrun(struct variable * vp, | |
24 | } else | 24 | } else | |
25 | long_return = 4; /* application */ | 25 | long_return = 4; /* application */ | |
26 | #else | 26 | #else | |
27 | + #if defined(dragonfly) && __DragonFly_version >= 190000 | 27 | + #if defined(dragonfly) && __DragonFly_version >= 190000 | |
28 | + if (proc_table[LowProcIndex].kp_flags & P_SYSTEM) | 28 | + if (proc_table[LowProcIndex].kp_flags & P_SYSTEM) | |
29 | + #else | 29 | + #else | |
30 | if (proc_table[LowProcIndex].kp_proc.p_flag & P_SYSTEM) | 30 | if (proc_table[LowProcIndex].kp_proc.p_flag & P_SYSTEM) | |
31 | + #endif | 31 | + #endif | |
32 | long_return = 2; /* operatingSystem */ | 32 | long_return = 2; /* operatingSystem */ | |
33 | else | 33 | else | |
34 | long_return = 4; /* application */ | 34 | long_return = 4; /* application */ | |
35 | #endif | 35 | #endif | |
36 | +#elif defined darwin | 36 | +#elif defined darwin | |
37 | + long_return = -1; | 37 | + long_return = -1; | |
38 | #else | 38 | #else | |
39 | long_return = 4; /* application */ | 39 | long_return = 4; /* application */ | |
40 | #endif | 40 | #endif | |
41 | @@ -962,6 +972,8 @@ | 41 | @@ -970,6 +980,8 @@ var_hrswrun(struct variable * vp, | |
42 | #if HAVE_KVM_GETPROCS | 42 | #if HAVE_KVM_GETPROCS | |
43 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | 43 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | |
44 | switch (proc_table[LowProcIndex].ki_stat) { | 44 | switch (proc_table[LowProcIndex].ki_stat) { | |
45 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 45 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
46 | + switch (proc_table[LowProcIndex].kp_stat) { | 46 | + switch (proc_table[LowProcIndex].kp_stat) { | |
47 | #else | 47 | #else | |
48 | switch (proc_table[LowProcIndex].kp_proc.p_stat) { | 48 | switch (proc_table[LowProcIndex].kp_proc.p_stat) { | |
49 | #endif | 49 | #endif | |
50 | @@ -1069,6 +1081,14 @@ | 50 | @@ -1077,6 +1089,14 @@ var_hrswrun(struct variable * vp, | |
51 | long_return = 0; | 51 | long_return = 0; | |
52 | #elif defined(freebsd5) | 52 | #elif defined(freebsd5) | |
53 | long_return = proc_table[LowProcIndex].ki_runtime / 100000; | 53 | long_return = proc_table[LowProcIndex].ki_runtime / 100000; | |
54 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 54 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
55 | + long_return = proc_table[LowProcIndex].kp_lwp.kl_uticks + | 55 | + long_return = proc_table[LowProcIndex].kp_lwp.kl_uticks + | |
56 | + proc_table[LowProcIndex].kp_lwp.kl_sticks + | 56 | + proc_table[LowProcIndex].kp_lwp.kl_sticks + | |
57 | + proc_table[LowProcIndex].kp_lwp.kl_iticks; | 57 | + proc_table[LowProcIndex].kp_lwp.kl_iticks; | |
58 | + #elif defined(dragonfly) | 58 | + #elif defined(dragonfly) | |
59 | + long_return = proc_table[LowProcIndex].kp_eproc.e_uticks + | 59 | + long_return = proc_table[LowProcIndex].kp_eproc.e_uticks + | |
60 | + proc_table[LowProcIndex].kp_eproc.e_sticks + | 60 | + proc_table[LowProcIndex].kp_eproc.e_sticks + | |
61 | + proc_table[LowProcIndex].kp_eproc.e_iticks; | 61 | + proc_table[LowProcIndex].kp_eproc.e_iticks; | |
62 | #else | 62 | #else | |
63 | long_return = proc_table[LowProcIndex].kp_proc.p_uticks + | 63 | long_return = proc_table[LowProcIndex].kp_proc.p_uticks + | |
64 | proc_table[LowProcIndex].kp_proc.p_sticks + | 64 | proc_table[LowProcIndex].kp_proc.p_sticks + | |
65 | @@ -1157,6 +1177,8 @@ | 65 | @@ -1169,6 +1189,8 @@ var_hrswrun(struct variable * vp, | |
66 | long_return = | 66 | long_return = | |
67 | #if defined(freebsd5) | 67 | #if defined(freebsd5) | |
68 | proc_table[LowProcIndex].ki_size / 1024; | 68 | proc_table[LowProcIndex].ki_size / 1024; | |
69 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 69 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
70 | + proc_table[LowProcIndex].kp_vm_map_size / 1024; | 70 | + proc_table[LowProcIndex].kp_vm_map_size / 1024; | |
71 | #else | 71 | #else | |
72 | proc_table[LowProcIndex].kp_eproc.e_vm.vm_map.size / 1024; | 72 | proc_table[LowProcIndex].kp_eproc.e_vm.vm_map.size / 1024; | |
73 | #endif | 73 | #endif | |
74 | @@ -1477,6 +1499,9 @@ | 74 | @@ -1489,6 +1511,9 @@ Get_Next_HR_SWRun(void) | |
75 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | 75 | #if defined(freebsd5) && __FreeBSD_version >= 500014 | |
76 | if (proc_table[current_proc_entry].ki_stat != 0) | 76 | if (proc_table[current_proc_entry].ki_stat != 0) | |
77 | return proc_table[current_proc_entry++].ki_pid; | 77 | return proc_table[current_proc_entry++].ki_pid; | |
78 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | 78 | + #elif defined(dragonfly) && __DragonFly_version >= 190000 | |
79 | + if (proc_table[current_proc_entry].kp_stat != 0) | 79 | + if (proc_table[current_proc_entry].kp_stat != 0) | |
80 | + return proc_table[current_proc_entry++].kp_pid; | 80 | + return proc_table[current_proc_entry++].kp_pid; | |
81 | #else | 81 | #else | |
82 | if (proc_table[current_proc_entry].kp_proc.p_stat != 0) | 82 | if (proc_table[current_proc_entry].kp_proc.p_stat != 0) | |
83 | return proc_table[current_proc_entry++].kp_proc.p_pid; | 83 | return proc_table[current_proc_entry++].kp_proc.p_pid; |
@@ -1,22 +1,22 @@ | @@ -1,22 +1,22 @@ | |||
1 | $NetBSD: patch-dc,v 1.4 2007/08/11 11:05:57 adam Exp $ | 1 | $NetBSD: patch-dc,v 1.5 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- include/net-snmp/net-snmp-config.h.in.orig 2007-07-19 23:00:35.000000000 +0200 | 3 | --- include/net-snmp/net-snmp-config.h.in.orig 2008-07-28 13:41:40.000000000 +0200 | |
4 | +++ include/net-snmp/net-snmp-config.h.in | 4 | +++ include/net-snmp/net-snmp-config.h.in | |
5 | @@ -1460,6 +1460,7 @@ | 5 | @@ -1463,6 +1463,7 @@ | |
6 | #define NETSNMP_HPUX11ID 14 | 6 | #define NETSNMP_HPUX11ID 14 | |
7 | #define NETSNMP_AIXID 15 | 7 | #define NETSNMP_AIXID 15 | |
8 | #define NETSNMP_MACOSXID 16 | 8 | #define NETSNMP_MACOSXID 16 | |
9 | +#define NETSNMP_DRAGONFLYID 17 | 9 | +#define NETSNMP_DRAGONFLYID 17 | |
10 | #define NETSNMP_UNKNOWNID 255 | 10 | #define NETSNMP_UNKNOWNID 255 | |
11 | 11 | |||
12 | #ifdef hpux9 | 12 | #ifdef hpux9 | |
13 | @@ -1489,6 +1490,9 @@ | 13 | @@ -1492,6 +1493,9 @@ | |
14 | #if defined(__FreeBSD__) | 14 | #if defined(__FreeBSD__) | |
15 | #define NETSNMP_OSTYPE NETSNMP_FREEBSDID | 15 | #define NETSNMP_OSTYPE NETSNMP_FREEBSDID | |
16 | #endif | 16 | #endif | |
17 | +#if defined(__DragonFly__) | 17 | +#if defined(__DragonFly__) | |
18 | +#define OSTYPE DRAGONFLYID | 18 | +#define OSTYPE DRAGONFLYID | |
19 | +#endif | 19 | +#endif | |
20 | #if defined(irix6) || defined(irix5) | 20 | #if defined(irix6) || defined(irix5) | |
21 | #define NETSNMP_OSTYPE NETSNMP_IRIXID | 21 | #define NETSNMP_OSTYPE NETSNMP_IRIXID | |
22 | #endif | 22 | #endif |
@@ -1,16 +1,16 @@ | @@ -1,16 +1,16 @@ | |||
1 | $NetBSD: patch-dn,v 1.1 2006/03/19 22:03:29 joerg Exp $ | 1 | $NetBSD: patch-dn,v 1.2 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/ucd-snmp/memory_freebsd2.c.orig 2006-03-19 20:27:45.000000000 +0000 | 3 | --- agent/mibgroup/ucd-snmp/memory_freebsd2.c.orig 2008-02-12 18:40:48.000000000 +0100 | |
4 | +++ agent/mibgroup/ucd-snmp/memory_freebsd2.c | 4 | +++ agent/mibgroup/ucd-snmp/memory_freebsd2.c | |
5 | @@ -10,8 +10,12 @@ | 5 | @@ -10,8 +10,12 @@ | |
6 | */ | 6 | */ | |
7 | #include <sys/param.h> | 7 | #include <sys/param.h> | |
8 | #include <sys/time.h> | 8 | #include <sys/time.h> | |
9 | +#ifdef dragonfly | 9 | +#ifdef dragonfly | |
10 | +#include <sys/user.h> | 10 | +#include <sys/user.h> | |
11 | +#else | 11 | +#else | |
12 | #include <sys/proc.h> | 12 | #include <sys/proc.h> | |
13 | #include <sys/dkstat.h> | 13 | #include <sys/dkstat.h> | |
14 | +#endif | 14 | +#endif | |
15 | #ifdef freebsd5 | 15 | #ifdef freebsd5 | |
16 | #include <sys/bio.h> | 16 | #include <sys/bio.h> | |
@@ -56,15 +56,15 @@ $NetBSD: patch-dn,v 1.1 2006/03/19 22:03 | @@ -56,15 +56,15 @@ $NetBSD: patch-dn,v 1.1 2006/03/19 22:03 | |||
56 | +#else | 56 | +#else | |
57 | long_ret = ptok(mem.v_free_count); | 57 | long_ret = ptok(mem.v_free_count); | |
58 | +#endif | 58 | +#endif | |
59 | return ((u_char *) (&long_ret)); | 59 | return ((u_char *) (&long_ret)); | |
60 | 60 | |||
61 | /* | 61 | /* | |
62 | @@ -351,6 +369,8 @@ var_extensible_mem(struct variable *vp, | 62 | @@ -351,6 +369,8 @@ var_extensible_mem(struct variable *vp, | |
63 | case MEMCACHED: | 63 | case MEMCACHED: | |
64 | #ifdef darwin | 64 | #ifdef darwin | |
65 | long_ret = ptok(mem.v_lookups); | 65 | long_ret = ptok(mem.v_lookups); | |
66 | +#elif defined(dragonfly) | 66 | +#elif defined(dragonfly) | |
67 | + long_ret = ptok(vmstats.v_cache_count); | 67 | + long_ret = ptok(vmstats.v_cache_count); | |
68 | #else | 68 | #else | |
69 | long_ret = ptok(mem.v_cache_count); | 69 | long_ret = ptok(mem.v_cache_count) + ptok(mem.v_inactive_count); | |
70 | #endif | 70 | #endif |
@@ -1,47 +1,47 @@ | @@ -1,47 +1,47 @@ | |||
1 | $NetBSD: patch-dr,v 1.1 2006/03/19 22:03:29 joerg Exp $ | 1 | $NetBSD: patch-dr,v 1.2 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/mibII/tcpTable.c.orig 2006-03-19 21:24:04.000000000 +0000 | 3 | --- agent/mibgroup/mibII/tcpTable.c.orig 2007-10-14 14:12:58.000000000 +0200 | |
4 | +++ agent/mibgroup/mibII/tcpTable.c | 4 | +++ agent/mibgroup/mibII/tcpTable.c | |
5 | @@ -711,7 +711,11 @@ tcpTable_load(netsnmp_cache *cache, void | 5 | @@ -719,7 +719,11 @@ tcpTable_load(netsnmp_cache *cache, void | |
6 | size_t len; | 6 | size_t len; | |
7 | int sname[] = { CTL_NET, PF_INET, IPPROTO_TCP, TCPCTL_PCBLIST }; | 7 | int sname[] = { CTL_NET, PF_INET, IPPROTO_TCP, TCPCTL_PCBLIST }; | |
8 | char *tcpcb_buf = NULL; | 8 | char *tcpcb_buf = NULL; | |
9 | +#if defined(dragonfly) | 9 | +#if defined(dragonfly) | |
10 | + struct xtcpcb *xig = NULL; | 10 | + struct xtcpcb *xig = NULL; | |
11 | +#else | 11 | +#else | |
12 | struct xinpgen *xig = NULL; | 12 | struct xinpgen *xig = NULL; | |
13 | +#endif | 13 | +#endif | |
14 | netsnmp_inpcb *nnew; | 14 | netsnmp_inpcb *nnew; | |
15 | int StateMap[] = { 1, 2, 3, 4, 5, 8, 6, 10, 9, 7, 11 }; | 15 | int StateMap[] = { 1, 2, 3, 4, 5, 8, 6, 10, 9, 7, 11 }; | |
16 | 16 | |||
17 | @@ -733,10 +737,18 @@ tcpTable_load(netsnmp_cache *cache, void | 17 | @@ -741,10 +745,18 @@ tcpTable_load(netsnmp_cache *cache, void | |
18 | * Unpick this into the constituent 'xinpgen' structures, and extract | 18 | * Unpick this into the constituent 'xinpgen' structures, and extract | |
19 | * the 'inpcb' elements into a linked list (built in reverse) | 19 | * the 'inpcb' elements into a linked list (built in reverse) | |
20 | */ | 20 | */ | |
21 | +#if defined(dragonfly) | 21 | +#if defined(dragonfly) | |
22 | + xig = (struct xtcpcb *) tcpcb_buf; | 22 | + xig = (struct xtcpcb *) tcpcb_buf; | |
23 | +#else | 23 | +#else | |
24 | xig = (struct xinpgen *) tcpcb_buf; | 24 | xig = (struct xinpgen *) tcpcb_buf; | |
25 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | 25 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | |
26 | +#endif | 26 | +#endif | |
27 | 27 | |||
28 | +#if defined(dragonfly) | 28 | +#if defined(dragonfly) | |
29 | + while (xig && ((char *)xig + xig->xt_len < tcpcb_buf + len)) { | 29 | + while (xig && ((char *)xig + xig->xt_len < tcpcb_buf + len)) { | |
30 | +#else | 30 | +#else | |
31 | while (xig && (xig->xig_len > sizeof(struct xinpgen))) { | 31 | while (xig && (xig->xig_len > sizeof(struct xinpgen))) { | |
32 | +#endif | 32 | +#endif | |
33 | nnew = SNMP_MALLOC_TYPEDEF(netsnmp_inpcb); | 33 | nnew = SNMP_MALLOC_TYPEDEF(netsnmp_inpcb); | |
34 | if (!nnew) | 34 | if (!nnew) | |
35 | break; | 35 | break; | |
36 | @@ -749,7 +761,11 @@ tcpTable_load(netsnmp_cache *cache, void | 36 | @@ -757,7 +769,11 @@ tcpTable_load(netsnmp_cache *cache, void | |
37 | 37 | |||
38 | nnew->inp_next = tcp_head; | 38 | nnew->inp_next = tcp_head; | |
39 | tcp_head = nnew; | 39 | tcp_head = nnew; | |
40 | +#if defined(dragonfly) | 40 | +#if defined(dragonfly) | |
41 | + xig = (struct xtcpcb *) ((char *) xig + xig->xt_len); | 41 | + xig = (struct xtcpcb *) ((char *) xig + xig->xt_len); | |
42 | +#else | 42 | +#else | |
43 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | 43 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | |
44 | +#endif | 44 | +#endif | |
45 | } | 45 | } | |
46 | 46 | |||
47 | free(tcpcb_buf); | 47 | free(tcpcb_buf); |
@@ -1,50 +1,52 @@ | @@ -1,50 +1,52 @@ | |||
1 | $NetBSD: patch-du,v 1.1 2007/02/05 19:19:14 joerg Exp $ | 1 | $NetBSD: patch-du,v 1.2 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/hardware/memory/memory_freebsd.c.orig 2007-02-05 18:25:59.000000000 +0000 | 3 | --- agent/mibgroup/hardware/memory/memory_freebsd.c.orig 2008-05-28 13:48:46.000000000 +0200 | |
4 | +++ agent/mibgroup/hardware/memory/memory_freebsd.c | 4 | +++ agent/mibgroup/hardware/memory/memory_freebsd.c | |
5 | @@ -36,6 +36,12 @@ int netsnmp_mem_arch_load( netsnmp_cache | 5 | @@ -36,6 +36,12 @@ int netsnmp_mem_arch_load( netsnmp_cache | |
6 | long pagesize; | 6 | long pagesize; | |
7 | int nswap; | 7 | int nswap; | |
8 | 8 | |||
9 | +#ifdef dragonfly | 9 | +#ifdef dragonfly | |
10 | + struct vmstats vms; | 10 | + struct vmstats vms; | |
11 | + size_t vms_size = sizeof(vms); | 11 | + size_t vms_size = sizeof(vms); | |
12 | + size_t vmem_size = sizeof(struct vmmeter); | 12 | + size_t vmem_size = sizeof(struct vmmeter); | |
13 | +#endif | 13 | +#endif | |
14 | + | 14 | + | |
15 | struct vmmeter vmem; | 15 | struct vmmeter vmem; | |
16 | struct vmtotal total; | 16 | struct vmtotal total; | |
17 | size_t total_size = sizeof(total); | 17 | size_t total_size = sizeof(total); | |
18 | @@ -53,12 +59,18 @@ int netsnmp_mem_arch_load( netsnmp_cache | 18 | @@ -58,12 +64,18 @@ int netsnmp_mem_arch_load( netsnmp_cache | |
19 | sysctl(total_mib, 2, &total, &total_size, NULL, 0); | |||
20 | sysctl(phys_mem_mib, 2, &phys_mem, &mem_size, NULL, 0); | |||
21 | sysctl(user_mem_mib, 2, &user_mem, &mem_size, NULL, 0); | 19 | sysctl(user_mem_mib, 2, &user_mem, &mem_size, NULL, 0); | |
20 | sysctlbyname("vfs.bufspace", &bufspace, &buf_size, NULL, 0); | |||
21 | sysctlbyname("vfs.maxbufspace", &maxbufspace, &buf_size, NULL, 0); | |||
22 | +#ifdef dragonfly | 22 | +#ifdef dragonfly | |
23 | + pagesize = getpagesize(); | 23 | + pagesize = getpagesize(); | |
24 | + sysctlbyname("vm.vmstats", & vms, &vms_size, NULL, 0); | 24 | + sysctlbyname("vm.vmstats", &vms, &vms_size, NULL, 0); | |
25 | + sysctlbyname("vm.vmmeter", & vmem, &vmem_size, NULL, 0); | 25 | + sysctlbyname("vm.vmmeter", &vmem, &vmem_size, NULL, 0); | |
26 | +#else | 26 | +#else | |
27 | auto_nlist(SUM_SYMBOL, (char *) &vmem, sizeof(vmem)); | 27 | auto_nlist(SUM_SYMBOL, (char *) &vmem, sizeof(vmem)); | |
28 | #ifndef freebsd4 | 28 | #ifndef freebsd4 | |
29 | pagesize = 1024; | 29 | pagesize = 1024; | |
30 | #else | 30 | #else | |
31 | pagesize = getpagesize(); | 31 | pagesize = getpagesize(); | |
32 | #endif | 32 | #endif | |
33 | +#endif | 33 | +#endif | |
34 | 34 | |||
35 | /* | 35 | /* | |
36 | * ... and save this in a standard form. | 36 | * ... and save this in a standard form. | |
37 | @@ -124,8 +136,13 @@ int netsnmp_mem_arch_load( netsnmp_cache | 37 | @@ -129,9 +141,15 @@ int netsnmp_mem_arch_load( netsnmp_cache | |
38 | } else { | 38 | } else { | |
39 | if (!mem->descr) | 39 | if (!mem->descr) | |
40 | mem->descr = strdup("Cached memory"); | 40 | mem->descr = strdup("Cached memory"); | |
41 | +#ifdef dragonfly | 41 | +#ifdef dragonfly | |
42 | + mem->units = vms.v_page_size; | 42 | + mem->units = vms.v_page_size; | |
43 | + mem->size = vms.v_cache_count; | 43 | + mem->size = vms.v_cache_max; | |
44 | + mem->free = vms.v_cache_max - vms.v_cache_count; | |||
44 | +#else | 45 | +#else | |
45 | mem->units = vmem.v_page_size; | 46 | mem->units = vmem.v_page_size; | |
46 | mem->size = vmem.v_cache_count; | 47 | mem->size = vmem.v_cache_max; | |
48 | mem->free = vmem.v_cache_max - vmem.v_cache_count; | |||
47 | +#endif | 49 | +#endif | |
48 | mem->free = -1; | |||
49 | } | 50 | } | |
50 | 51 | |||
52 | nswap = swapmode(pagesize); |
@@ -1,47 +1,47 @@ | @@ -1,47 +1,47 @@ | |||
1 | $NetBSD: patch-ds,v 1.3 2007/02/05 12:06:16 adam Exp $ | 1 | $NetBSD: patch-ds,v 1.4 2008/09/08 12:58:09 adam Exp $ | |
2 | 2 | |||
3 | --- agent/mibgroup/mibII/udpTable.c.orig 2006-11-07 00:43:27.000000000 +0100 | 3 | --- agent/mibgroup/mibII/udpTable.c.orig 2008-02-13 17:12:42.000000000 +0100 | |
4 | +++ agent/mibgroup/mibII/udpTable.c | 4 | +++ agent/mibgroup/mibII/udpTable.c | |
5 | @@ -617,7 +617,11 @@ udpTable_load(netsnmp_cache *cache, void | 5 | @@ -619,7 +619,11 @@ udpTable_load(netsnmp_cache *cache, void | |
6 | size_t len; | 6 | size_t len; | |
7 | int sname[] = { CTL_NET, PF_INET, IPPROTO_UDP, UDPCTL_PCBLIST }; | 7 | int sname[] = { CTL_NET, PF_INET, IPPROTO_UDP, UDPCTL_PCBLIST }; | |
8 | char *udpcb_buf = NULL; | 8 | char *udpcb_buf = NULL; | |
9 | +#if defined(dragonfly) | 9 | +#if defined(dragonfly) | |
10 | + struct xinpcb *xig = NULL; | 10 | + struct xinpcb *xig = NULL; | |
11 | +#else | 11 | +#else | |
12 | struct xinpgen *xig = NULL; | 12 | struct xinpgen *xig = NULL; | |
13 | +#endif | 13 | +#endif | |
14 | UDPTABLE_ENTRY_TYPE *nnew; | 14 | UDPTABLE_ENTRY_TYPE *nnew; | |
15 | 15 | |||
16 | udpTable_free(NULL, NULL); | 16 | udpTable_free(NULL, NULL); | |
17 | @@ -638,10 +642,18 @@ udpTable_load(netsnmp_cache *cache, void | 17 | @@ -640,10 +644,18 @@ udpTable_load(netsnmp_cache *cache, void | |
18 | * Unpick this into the constituent 'xinpgen' structures, and extract | 18 | * Unpick this into the constituent 'xinpgen' structures, and extract | |
19 | * the 'inpcb' elements into a linked list (built in reverse) | 19 | * the 'inpcb' elements into a linked list (built in reverse) | |
20 | */ | 20 | */ | |
21 | +#if defined(dragonfly) | 21 | +#if defined(dragonfly) | |
22 | + xig = (struct xinpcb *) udpcb_buf; | 22 | + xig = (struct xinpcb *) udpcb_buf; | |
23 | +#else | 23 | +#else | |
24 | xig = (struct xinpgen *) udpcb_buf; | 24 | xig = (struct xinpgen *) udpcb_buf; | |
25 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | 25 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | |
26 | +#endif | 26 | +#endif | |
27 | 27 | |||
28 | +#if defined(dragonfly) | 28 | +#if defined(dragonfly) | |
29 | + while (xig && ((char *)xig + xig->xi_len < udpcb_buf + len)) { | 29 | + while (xig && ((char *)xig + xig->xi_len < udpcb_buf + len)) { | |
30 | +#else | 30 | +#else | |
31 | while (xig && (xig->xig_len > sizeof(struct xinpgen))) { | 31 | while (xig && (xig->xig_len > sizeof(struct xinpgen))) { | |
32 | +#endif | 32 | +#endif | |
33 | nnew = SNMP_MALLOC_TYPEDEF(UDPTABLE_ENTRY_TYPE); | 33 | nnew = SNMP_MALLOC_TYPEDEF(UDPTABLE_ENTRY_TYPE); | |
34 | if (!nnew) | 34 | if (!nnew) | |
35 | break; | 35 | break; | |
36 | @@ -654,7 +666,11 @@ udpTable_load(netsnmp_cache *cache, void | 36 | @@ -656,7 +668,11 @@ udpTable_load(netsnmp_cache *cache, void | |
37 | #endif | 37 | #endif | |
38 | 38 | |||
39 | udp_head = nnew; | 39 | udp_head = nnew; | |
40 | +#if defined(dragonfly) | 40 | +#if defined(dragonfly) | |
41 | + xig = (struct xinpcb *) ((char *) xig + xig->xi_len); | 41 | + xig = (struct xinpcb *) ((char *) xig + xig->xi_len); | |
42 | +#else | 42 | +#else | |
43 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | 43 | xig = (struct xinpgen *) ((char *) xig + xig->xig_len); | |
44 | +#endif | 44 | +#endif | |
45 | } | 45 | } | |
46 | 46 | |||
47 | free(udpcb_buf); | 47 | free(udpcb_buf); |