Rob,
Sorry! Pilot error. I was looking at multiple issues and I gto somewhat confused. Again very sorry about this.
I am in the middle of writing an agentx subagent. I have the handler all set up and registered using netsnmp_register_handler, it get my requests. The problem is I don't know what to do from there. If I try to set the value of the requests->requestvp and return 0 the subagent runs and eats memory until the system hangs. About 1.5Gig in 2 minutes! I am trying to track down the code where my handler is called bu t I can 't seem to find it.
Does anyone know of an example subagent that is a little more in depth than the tutorial? I am using netsnmp_create_handler_registration and netsnmp_register_handler. My handler function returns 0. Is that correct? Also what is the expected way to return the values, just malloc the correct val and set it or what?
Thanks
Glenn
Robert Story (Coders) wrote:
On Tue, 08 Jun 2004 16:55:10 -0400 Glenn wrote:
GM> I am using net-snmp 5.1.1. I have written an app that needs to read all GM> the mib files in a give directory, which should happen in init_mib but GM> it is not.
GM> GM> I have tracked it down to the fscanf in the add_mibdir function in parse.c
GM> GM> while (fscanf(ip, "%127s%c%299s%c", token, &space, tmpstr, &newline) == 4)
GM> {...
GM> }
GM> GM> This is returning -1 so no mibs are getting read. The .index file has GM> the following format
GM> GM> MODULE MIBFILE
GM> MODULE MIBFILE
GM> ...
GM> GM> Is this a known issue or should I fix and send a patch?
Well, I'm not sure what you are proposing to change. Have you tried deleting your .index file so it will be regenerated?
------------------------------------------------------- This SF.Net email is sponsored by: GNOME Foundation Hackers Unite! GUADEC: The world's #1 Open Source Desktop Event. GNOME Users and Developers European Conference, 28-30th June in Norway http://2004/guadec.org _______________________________________________ Net-snmp-coders mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
