[tkined] mib unpack returns invalid value

From: Tim Westbrook (iondiode@yahoo.com)
Date: Tue Dec 05 2000 - 06:49:23 MET

    Is this a bug or am I misunderstanding something?

I have a mib object that is indexed by ATM address (
20bytes). something like...

        AtmAddr ::= OCTET STRING (SIZE(0..20))

    When I do a [ Tnm::mib unpack $oid], the value
returned is a hexadecimal concatenation of the MIB
octets from the PDU. Which is what you would expect!
    But the bytes are all truncated that is, what
should be 0x0F comes out as 0xF.
    I was able to make a change to the formatOctetTC
function so that case 'x' triggers a %.2lx format
command instead of just %lx ( i may not have all the
code right I dont have it in front of me). This works
for now.
     But, I am fairly new to c and I am wondering what
kind of problems this may introduce?

Thanks for your time,

Do You Yahoo!?
Yahoo! Shopping - Thousands of Stores. Millions of Products.

!! This message is brought to you via the `tkined & scotty' mailing list.
!! Please do not reply to this message to unsubscribe. To subscribe or
!! unsubscribe, send a mail message to <tkined-request@ibr.cs.tu-bs.de>.
!! See http://wwwsnmp.cs.utwente.nl/~schoenw/scotty/ for more information.

This archive was generated by hypermail 2b29 : Mon Jan 08 2001 - 15:27:58 MET