aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp
diff options
context:
space:
mode:
authorColton <[email protected]>2014-04-11 07:56:41 -0500
committerColton <[email protected]>2014-04-11 07:56:41 -0500
commitb358cc5882014aefc379ff40794cbfed876627e6 (patch)
tree84f99b54e830ae1d6d405e3b3ffaba8adfe9d30d /lib/snmp
parent8acc644e162bad52f7ab81c76c0cad15628e4f3d (diff)
downloadotp-b358cc5882014aefc379ff40794cbfed876627e6.tar.gz
otp-b358cc5882014aefc379ff40794cbfed876627e6.tar.bz2
otp-b358cc5882014aefc379ff40794cbfed876627e6.zip
Edit line 59 to remove "mgr" key from #State record.
Edit line 133 to expect ok instead of {ok, Pid} from snmpm:start_link . Edit line 136 not to reference Pid variable which was removed above.
Diffstat (limited to 'lib/snmp')
-rw-r--r--lib/snmp/test/snmp_test_manager.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/snmp/test/snmp_test_manager.erl b/lib/snmp/test/snmp_test_manager.erl
index 925ae77ab5..6d8673eecd 100644
--- a/lib/snmp/test/snmp_test_manager.erl
+++ b/lib/snmp/test/snmp_test_manager.erl
@@ -56,7 +56,7 @@
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
code_change/3, terminate/2]).
--record(state, {mgr, parent, req, agent_target_name}).
+-record(state, {parent, req, agent_target_name}).
-define(SERVER, ?MODULE).
-define(USER, ?MODULE).
@@ -130,10 +130,10 @@ init([Parent, Opts]) ->
do_init(Opts) ->
{MgrDir, MgrConf, MgrOpts, AgentTargetName, AgentConf} = parse_opts(Opts),
ok = snmp_config:write_manager_config(MgrDir, "", MgrConf),
- {ok, Pid} = snmpm:start_link(MgrOpts),
+ ok = snmpm:start_link(MgrOpts),
ok = snmpm:register_user(?USER, ?MODULE, self()),
ok = snmpm:register_agent(?USER, AgentTargetName, AgentConf),
- {ok, #state{mgr = Pid, agent_target_name = AgentTargetName}}.
+ {ok, #state{agent_target_name = AgentTargetName}}.
parse_opts(Opts) ->