Hi all!

I work on a project based on NET-SNMP source code. At moment I use
version 5.1.1 (but what I report appear to be valid in 5.2pre3 too). I
was suspecting a memory leakage in some of snmpget components and I made
a trivial modification in snmpget.c (see attached code), in order to
iterate snmpget funcionality and trying to expose any potential leakage.
Maybe I'm doing wrong but what I see from 'top' or /proc process
information is a growing memory usage. In particular these are the
ever-growing figures:

VmSize:     6312 kB
VmRSS:      2160 kB
VmData:      736 kB

Note that this test makes correct requests to the agent (valid oid) and
returned values are consistent.
I understand this could be a no-problem for a command line tools like
snmpget, but it is critical in my project since I do provide snmpget
functionalities through a library function. What reported appear to be
present in both Linux and Win32 builds.

I'm not an expert in using debugging and profiling tools, so any help
will be appreciated to understand (and possibly solve) this problem. I'd
like to help in tracking this thing down, if possible. Since I can't
state where the leakage is (if it is really so...) I'm possibly
reporting an already known problem: please forgive me if so. ;-)

Regards,
Andrea


Modified snmpget.c follows:
--

int
main(int argc, char *argv[])
{
        while(1) {
                _main(argc, argv);
        }
}

int
_main(int argc, char *argv[])
{

<unmodified original main()>

}



-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
_______________________________________________
Net-snmp-users mailing list
[EMAIL PROTECTED]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to