Hello,

 

I'm using net-snmp v5.7.2 and the mib2c tool.

When I'm trying to set and created values for table I defined, I got error
that the set operation had failed.

After investigation I found out that in each table, which had been defined I
see in the xxxTable_interface.c inside 

_xxxTable_initialize_interface() function,  the following code:

 

    reginfo = netsnmp_handler_registration_create("xxxTable", handler,

                                                  xxxTable_oid,

                                                  xxxTable_oid_size,

                                                  HANDLER_CAN_BABY_STEP |

#if !(defined(NETSNMP_NO_WRITE_SUPPORT) ||
defined(NETSNMP_DISABLE_SET_SUPPORT))

                                                  HANDLER_CAN_RONLY

#else

                                                  HANDLER_CAN_RWRITE

#endif /* NETSNMP_NO_WRITE_SUPPORT || NETSNMP_DISABLE_SET_SUPPORT */

 

 

The above generated code doesn't make sense, because if
NETSNMP_NO_WRITE_SUPPORT & NETSNMP_DISABLE_SET_SUPPORT 

are not defined the mode should be  HANDLER_CAN_RWRITE and read only.

 

For example, in ifTable_interface.c the code is as following:

 

    reginfo =

        netsnmp_handler_registration_create("ifTable", handler,

                                            ifTable_oid, ifTable_oid_size,

                                            HANDLER_CAN_BABY_STEP |

#if !(defined(NETSNMP_NO_WRITE_SUPPORT) ||
defined(NETSNMP_DISABLE_SET_SUPPORT))

                                            HANDLER_CAN_RWRITE

#else

                                            HANDLER_CAN_RONLY

#endif /* NETSNMP_NO_WRITE_SUPPORT || NETSNMP_DISABLE_SET_SUPPORT */

 

In the other places in the code generated which use the macro
NETSNMP_NO_WRITE_SUPPORT or NETSNMP_DISABLE_SET_SUPPORT

The code is reasonable.

 

Does anyone familiar with this problem? Did I configures something wrong?

 

Thank's in advance. 

 

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
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