in reply to Net::SNMP result oddity

Hi,

I don't have an SNMP-enabled device handy that I can test your code on, and I don't see anything obviously wrong with a cursory look.... however, when I encounter problems like this I generally reach for Data::Dumper.

Try inserting a..

print Dumper($result);
just before your first foreach loop, and then a..
print Dumper($macTable);
just before your second.

This should be enough to tell you whether the data is coming back mangled, or if it's your hash assignments doing the mangling.

Hope this helps,
Darren :)