Hi,
Does anything actually use EIGHTBIT_SUBIDS anymore is is this a hangover
from a old code? It doesn't seem to be configurable from autoconf and
unless your very careful with your MIB structure it's likely to break.
commit a0ca9fbf88b0480dfe74d1d057747495eda3cd7f
Author: Alex Bennee <[EMAIL PROTECTED]>
Date: Mon Apr 14 11:24:10 2008 +0100
Removed support for EIGHTBIT_SUBIDS
As far as I can tell you can't enable these through configure and without
very carefully contructed MIBS you could easily break.
diff --git a/tags/Ext-5-4-1/net-snmp/include/net-snmp/library/asn1.h
b/tags/Ext-5-4-1/net-snmp/include/net-snmp/library/asn1.h
index f132f3b..baf4b9f 100644
--- a/tags/Ext-5-4-1/net-snmp/include/net-snmp/library/asn1.h
+++ b/tags/Ext-5-4-1/net-snmp/include/net-snmp/library/asn1.h
@@ -38,13 +38,8 @@ SOFTWARE.
#ifndef MAX_SUBID /* temporary - duplicate definition protection
*/
-#ifndef EIGHTBIT_SUBIDS
typedef u_long oid;
#define MAX_SUBID 0xFFFFFFFF
-#else
- typedef u_char oid;
-#define MAX_SUBID 0xFF
-#endif
#endif
#define MIN_OID_LEN 2
diff --git a/tags/Ext-5-4-1/net-snmp/include/net-snmp/types.h
b/tags/Ext-5-4-1/net-snmp/include/net-snmp/types.h
index 0592004..5349d9e 100644
--- a/tags/Ext-5-4-1/net-snmp/include/net-snmp/types.h
+++ b/tags/Ext-5-4-1/net-snmp/include/net-snmp/types.h
@@ -46,13 +46,8 @@ extern "C" {
#endif
#ifndef MAX_SUBID /* temporary - duplicate definition protection
*/
-#ifndef EIGHTBIT_SUBIDS
typedef u_long oid;
#define MAX_SUBID 0xFFFFFFFF
-#else
-typedef u_char oid;
-#define MAX_SUBID 0xFF
-#endif
#endif
#ifndef HAVE_SOCKLEN_T
diff --git a/tags/Ext-5-4-1/net-snmp/snmplib/asn1.c
b/tags/Ext-5-4-1/net-snmp/snmplib/asn1.c
index dd02bea..16232fd 100644
--- a/tags/Ext-5-4-1/net-snmp/snmplib/asn1.c
+++ b/tags/Ext-5-4-1/net-snmp/snmplib/asn1.c
@@ -1327,7 +1327,7 @@ asn_parse_objid(u_char * data,
length--;
} while (*(u_char *) bufp++ & ASN_BIT8); /* last byte has high
bit clear */
-#if defined(EIGHTBIT_SUBIDS) || (SIZEOF_LONG != 4)
+#if (SIZEOF_LONG != 4)
if (subidentifier > (u_long) MAX_SUBID) {
ERROR_MSG("subidentifier too large");
return NULL;
--
Alex Bennee
Software Engineer, Cambridge Broadband
------------------------------------------------------------------------------
Cambridge Broadband Networks Limited
Registered in England and Wales under company number: 03879840
Registered office: Selwyn House, Cambridge Business Park, Cowley Road,
Cambridge CB4 0WZ, UK.
VAT number: GB 741 0186 64
This email and any attachments are private and confidential. If you believe you
have received this email in error please inform the sender and delete it from
your mailbox or any other storage mechanism. Cambridge Broadband Networks
Limited cannot accept liability for any statements made which are clearly the
individual sender's own and not expressly made on behalf of Cambridge Broadband
Networks Limited.
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders