aboutsummaryrefslogtreecommitdiffstats
path: root/lib/diameter/src/base/diameter_peer_fsm.erl
diff options
context:
space:
mode:
authorAnders Svensson <[email protected]>2012-08-28 15:05:30 +0200
committerAnders Svensson <[email protected]>2012-08-28 15:05:30 +0200
commitafd9de758fc7977e03df376e628bd8e5143dd51d (patch)
tree90e37064daa41b69660967bad0cd6c6966cd1925 /lib/diameter/src/base/diameter_peer_fsm.erl
parent88c13abb6e803c2be0288ce0c46f080e951fc8b0 (diff)
parent34920eaa016af20226da0a6dc44d3cd8b9cf4abe (diff)
downloadotp-afd9de758fc7977e03df376e628bd8e5143dd51d.tar.gz
otp-afd9de758fc7977e03df376e628bd8e5143dd51d.tar.bz2
otp-afd9de758fc7977e03df376e628bd8e5143dd51d.zip
Merge branch 'anders/diameter/statistics/OTP-9608' into maint
* anders/diameter/statistics/OTP-9608: Improve statistics test cases Statistics fixes
Diffstat (limited to 'lib/diameter/src/base/diameter_peer_fsm.erl')
-rw-r--r--lib/diameter/src/base/diameter_peer_fsm.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/diameter/src/base/diameter_peer_fsm.erl b/lib/diameter/src/base/diameter_peer_fsm.erl
index ca2e8c56cb..302540e76b 100644
--- a/lib/diameter/src/base/diameter_peer_fsm.erl
+++ b/lib/diameter/src/base/diameter_peer_fsm.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2010-2011. All Rights Reserved.
+%% Copyright Ericsson AB 2010-2012. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -131,11 +131,10 @@
%% specified on the transport in question. Check here that the list is
%% still non-empty.
-start({_, Ref} = Type, Opts, #diameter_service{applications = Apps} = Svc) ->
+start({_,_} = Type, Opts, #diameter_service{applications = Apps} = Svc) ->
[] /= Apps orelse ?ERROR({no_apps, Type, Opts}),
T = {self(), Type, Opts, Svc},
{ok, Pid} = diameter_peer_fsm_sup:start_child(T),
- diameter_stats:reg(Pid, Ref),
Pid.
start_link(T) ->
@@ -157,6 +156,7 @@ init(T) ->
i({WPid, T, Opts, #diameter_service{capabilities = Caps} = Svc}) ->
putr(?DWA_KEY, dwa(Caps)),
{M, Ref} = T,
+ diameter_stats:reg(Ref),
{[Ts], Rest} = proplists:split(Opts, [capabilities_cb]),
putr(?CB_KEY, {Ref, [F || {_,F} <- Ts]}),
erlang:monitor(process, WPid),