Menu

#454 Callback

closed
library (262)
1
2012-11-08
2002-06-18
Anonymous
No

int Switch_PollCallback(int op, struct snmp_session
*sp, int reqid, struct snmp_pdu *pdu, void *magic)
{
if ( op == RECEIVED_MESSAGE )
{
struct variable_list *vp = pdu->variables;
if ( pdu->errstat == SNMP_ERR_NOERROR )
{
cout << pdu << " " << vp << endl;

-------------------->

0xe0b78 0x251
0xca550 0x251
0xc7ea8 0x251
0xc7680 0x251
0xc6e58 0x251
0xbcc00 0x251
0xb9508 0x251
0xb84b8 0x251
0xb74a0 0x251
0x8d820 0x251

------------------------

The linked list doesn't seem to be initialised.. or
nullified.. on Solaris using version 5.0.1

Discussion

  • John Naylon

    John Naylon - 2002-07-01

    Logged In: YES
    user_id=93926

    I don't really understand what you are expecting your code
    to do. The toolkit doesn't support C++ in the way that you
    are apparently anticipating.

     
  • Nobody/Anonymous

    Logged In: NO

    When the API calls the function given in callback it does it
    with a wrong pointer... the addresse should be 0x00000 or
    something meaningful... with 0x251 it will segfault... and i'm
    not even able to test it with something like if ( ptr == NULL )
    is it normal?

    -Fred

     

Log in to post a comment.