aboutsummaryrefslogtreecommitdiffstats
path: root/lib/diameter/src/transport
diff options
context:
space:
mode:
authorAnders Svensson <[email protected]>2011-10-09 20:35:20 +0200
committerAnders Svensson <[email protected]>2011-10-10 11:24:00 +0200
commit698360f3a8c7bb8298d70ccc054cd2124a11f10e (patch)
tree9087b195ae4f97d741375ebc5eb7569627d15654 /lib/diameter/src/transport
parent7b4bd37903c5d740c009adc6655db0e15587681a (diff)
downloadotp-698360f3a8c7bb8298d70ccc054cd2124a11f10e.tar.gz
otp-698360f3a8c7bb8298d70ccc054cd2124a11f10e.tar.bz2
otp-698360f3a8c7bb8298d70ccc054cd2124a11f10e.zip
Register tcp listener before transport start return
Diffstat (limited to 'lib/diameter/src/transport')
-rw-r--r--lib/diameter/src/transport/diameter_tcp.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/diameter/src/transport/diameter_tcp.erl b/lib/diameter/src/transport/diameter_tcp.erl
index a15c49f4a7..78dbda6888 100644
--- a/lib/diameter/src/transport/diameter_tcp.erl
+++ b/lib/diameter/src/transport/diameter_tcp.erl
@@ -158,9 +158,9 @@ i({listen, LRef, APid, {Mod, Opts, Addrs}}) ->
LAddr = get_addr(LA, Addrs),
LPort = get_port(LP),
{ok, LSock} = Mod:listen(LPort, gen_opts(LAddr, Rest)),
+ true = diameter_reg:add_new({?MODULE, listener, {LRef, {LAddr, LSock}}}),
proc_lib:init_ack({ok, self(), {LAddr, LSock}}),
erlang:monitor(process, APid),
- true = diameter_reg:add_new({?MODULE, listener, {LRef, {LAddr, LSock}}}),
start_timer(#listener{socket = LSock}).
ssl(Opts) ->