SNMP: set commit fail error
This commit is contained in:
parent
dd1e5966fb
commit
d2c3b903f1
2 changed files with 7 additions and 5 deletions
|
|
@ -753,6 +753,7 @@ clixon_snmp_scalar_handler1(netsnmp_mib_handler *handler,
|
||||||
goto done;
|
goto done;
|
||||||
if (ret == 0){
|
if (ret == 0){
|
||||||
clicon_rpc_discard_changes(sh->sh_h);
|
clicon_rpc_discard_changes(sh->sh_h);
|
||||||
|
retval = SNMP_ERR_COMMITFAILED;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
@ -1310,6 +1311,7 @@ clixon_snmp_table_handler1(netsnmp_mib_handler *handler,
|
||||||
goto done;
|
goto done;
|
||||||
if (ret == 0){
|
if (ret == 0){
|
||||||
clicon_rpc_discard_changes(sh->sh_h);
|
clicon_rpc_discard_changes(sh->sh_h);
|
||||||
|
retval = SNMP_ERR_COMMITFAILED;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -198,7 +198,7 @@ clixon_snmp_input_cb(int s,
|
||||||
clicon_handle h = (clicon_handle)arg;
|
clicon_handle h = (clicon_handle)arg;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
clicon_debug(1, "%s %d", __FUNCTION__, s);
|
clicon_debug(2, "%s %d", __FUNCTION__, s);
|
||||||
FD_ZERO(&readfds);
|
FD_ZERO(&readfds);
|
||||||
FD_SET(s, &readfds);
|
FD_SET(s, &readfds);
|
||||||
(void)snmp_read(&readfds);
|
(void)snmp_read(&readfds);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue