Rolled back the previous IP getting patch, and Report connection's IP address

SVN Revision: 1452
This commit is contained in:
Christophe Romain 2008-07-16 13:30:37 +00:00
parent 546bb02153
commit 745106c83d
1 changed files with 2 additions and 4 deletions

View File

@ -274,8 +274,7 @@ code_change(_OldVsn, State, _Extra) ->
%%--------------------------------------------------------------------
activate_socket(#state{socket = Socket,
sock_mod = SockMod,
c2s_pid = C2SPid}) ->
sock_mod = SockMod}) ->
PeerName =
case SockMod of
gen_tcp ->
@ -288,8 +287,7 @@ activate_socket(#state{socket = Socket,
case PeerName of
{error, _Reason} ->
self() ! {tcp_closed, Socket};
{ok, IP} ->
C2SPid ! {peername, IP},
{ok, _} ->
ok
end.