I just started writing C code with the 5.1.2 API ... no agent stuff, 
just some gets for right now.

  But I was trying to print an OID (system.sysObjectID).  The expected 
string would print, but then all kinds of numeric jibberish was appended 
to it (using snprint_objid).  The val_len after the get 72 which I knew 
was too long.  I used the print_variable() call to verify my in-memory 
SNMP response was good; it printed the expected information correctly.

  Only after I plunged into the mib.c file did I discover that I was to 
divide the val_len by sizeof(oid).  I did it and it worked for my code. 
So my question is ... while looking at the tutorials, FAQ, and apps in 
the app directory, did I miss some place where something talks about 
this mysterious division by sizeof(oid)?  Because, if so, then I've 
probably missed other huge topics that will become time sinks later on.  
Should I be looking someplace else?

  Shane

-- 

Shane A. Dawalt
Senior Network Engineer
Wright State University
Dayton,  OH  45435
Phone:  937-775-4089           Email: [EMAIL PROTECTED]


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to