Re: collect HUP signal

Manfred Wassmann <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
On Thu, 31 Jan 2008, Meilán García Antonio wrote:

> So my question are:
>
> 1.- how can I register a function in my module for execute the routines
> for freeing all memory before restart snmpd (just when snmpd receives
> also the HUP signal)?

snmp_register_callback(SNMP_CALLBACK_APPLICATION,
                        SNMPD_CALLBACK_PRE_UPDATE_CONFIG
                        myCallbackFunction, myData)

This should do the job if myCallbackFunction is defined like

myCallbackFunction(int majorID, int minorID, void *serverarg, void *clientarg)

myData is passed as clientarg to the invocation of myCallback.

>
> 2.- Are there some routine for freeing all memory of my module process
> quickly or I have to unregister table to table and old that?

Sorry, I don't know that.

HTH

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

_______________________________________________
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
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.