
did you mean this?
//Marcin
---------- Forwarded message ---------- Date: Fri, 6 Jan 2012 23:40:26 From: Koen Van Hoof koen.van_hoof@alcatel-lucent.com To: "libsmi@ibr.cs.tu-bs.de" libsmi@ibr.cs.tu-bs.de Subject: [libsmi] parse all our mibs
Hi,
In order to be able to parse all our mibs, I have made some changes to libsmi. Here are my proposed changes. (See attached patches).
1) I have added SMI_ACCESS_WRITE_ONLY, because in SMIv1 this is also a valid access. 2) I have added SMI_BASETYPE_CHOICE. If the CHOICE type was SMI_BASETYPE_UNKNOWN, an import of that type caused a failure. 3) For the enum values of SMI_BASETYPE_ENUM, also the lists of the parent types are checked. 4) In SMIv1 'INTEGER(0..4294967295)' is vallid. In order to be able to parse this, a selection between SMI_BASETYPE_INTEGER32, SMI_BASETYPE_UNSIGNED64 and SMI_BASETYPE_UNSIGNED32 is made, based on the range of the integerSubType. 5) For SMIv1, the status 'mandatory', 'deprecated', 'obsolete' and 'optional' are parsed, and set to SMI_STATUS_MANDATORY, SMI_STATUS_DEPRECATED, SMI_STATUS_OBSOLETE and SMI_STATUS_OPTIONAL. 6) I have changed the check '(a->value.unsigned32> 1)&& (a->value.unsigned32-1> 2147483647))' into '(a->value.unsigned32>= 0x80000000u)'. This does not give any overflow, because it's an unsigned comparison (Notice the 'u' at the end of 0x80000000u. 7) In the last if statement, the result of compareValues was wrong, the parameters of the subtraction had to be switched.
I have tested this with 'smi_dump -f xml' and the output is much better now.
I hope my changes can contribute.
:-) Koen Van Hoof
-- !! This message is brought to you via the `libsmi' mailing list. !! Please do not reply to this message to unsubscribe. To unsubscribe or adjust !! your settings, send a mail message to libsmi-request@ibr.cs.tu-bs.de !! or look at https://www.ibr.cs.tu-bs.de/mailman/listinfo/libsmi.

On Wed, Jan 11, 2012 at 12:55:12PM +0000, Marcin Cieslak wrote:
did you mean this?
yep, I meanwhile found it also in some other folder
/js
participants (2)
-
Juergen Schoenwaelder
-
Marcin Cieslak