diff options
author | Micael Karlberg <[email protected]> | 2013-10-09 11:38:17 +0200 |
---|---|---|
committer | Micael Karlberg <[email protected]> | 2013-10-09 11:38:17 +0200 |
commit | 832e4112fc2d43face974333660f6c99ba5d686e (patch) | |
tree | ab4ee0f9eb1c919511e3ad3c9c60c99f07d6c316 /lib/snmp/test/snmp_test_manager.erl | |
parent | f9f49c3ae40eef669ed165efdc4b03ecb551a8a0 (diff) | |
parent | 7558861af77de9405decc8d88b2c799e15f266da (diff) | |
download | otp-832e4112fc2d43face974333660f6c99ba5d686e.tar.gz otp-832e4112fc2d43face974333660f6c99ba5d686e.tar.bz2 otp-832e4112fc2d43face974333660f6c99ba5d686e.zip |
Merge branch 'bmk/snmp/manager/improve_user_callback_response_handling2/OTP-11307' into bmk/snmp/snmp425_integration
Conflicts:
lib/snmp/doc/src/notes.xml
lib/snmp/src/app/snmp.appup.src
Diffstat (limited to 'lib/snmp/test/snmp_test_manager.erl')
-rw-r--r-- | lib/snmp/test/snmp_test_manager.erl | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/lib/snmp/test/snmp_test_manager.erl b/lib/snmp/test/snmp_test_manager.erl index 1f3383a7a8..925ae77ab5 100644 --- a/lib/snmp/test/snmp_test_manager.erl +++ b/lib/snmp/test/snmp_test_manager.erl @@ -47,7 +47,8 @@ handle_pdu/4, handle_trap/3, handle_inform/3, - handle_report/3 + handle_report/3, + handle_invalid_result/3 ]). @@ -279,12 +280,18 @@ handle_info({snmp_inform, TargetName, Info, Pid}, handle_info({snmp_report, TargetName, Info, Pid}, #state{parent = P} = State) -> info_msg("received snmp report: " - "~n TargetName: ~p" - "~n Info: ~p", [TargetName, Info]), + "~n TargetName: ~p" + "~n Info: ~p", [TargetName, Info]), Pid ! {snmp_report_reply, ignore, self()}, P ! {snmp_report, TargetName, Info}, {noreply, State}; +handle_info({snmp_invalid_result, In, Out}, State) -> + error_msg("Callback failure: " + "~n In: ~p" + "~n Out: ~p", [In, Out]), + {noreply, State}; + handle_info(Info, State) -> error_msg("received unknown info: " "~n Info: ~p", [Info]), @@ -369,7 +376,12 @@ handle_report(TargetName, SnmpInfo, Pid) -> after 10000 -> ignore end. - + + +handle_invalid_result(In, Out, Pid) -> + Pid ! {snmp_invalid_result, In, Out}, + ignore. + %%---------------------------------------------------------------------- |