summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2012-01-30 11:23:36 +0000
committerMatthias Radestock <matthias@rabbitmq.com>2012-01-30 11:23:36 +0000
commitcdd483cd673a9fff71a744ea986be603f7c21fb0 (patch)
tree7a66f7514e6795ced686d2223c6fee8ed97a17d6 /src
parentee1d5c3cc6343b258a5d879e7828c4c40e577819 (diff)
downloadrabbitmq-server-git-cdd483cd673a9fff71a744ea986be603f7c21fb0.tar.gz
produce only one log entry for abnormal connection closure
instead of two
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_reader.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rabbit_reader.erl b/src/rabbit_reader.erl
index 864d77957e..e642c20dca 100644
--- a/src/rabbit_reader.erl
+++ b/src/rabbit_reader.erl
@@ -225,15 +225,15 @@ start_connection(Parent, ChannelSupSupPid, Collector, StartHeartbeatFun, Deb,
try
recvloop(Deb, switch_callback(rabbit_event:init_stats_timer(
State, #v1.stats_timer),
- handshake, 8))
+ handshake, 8)),
+ log(info, "closing AMQP connection ~p (~s)~n", [self(), ConnStr])
catch
Ex -> log(case Ex of
connection_closed_abruptly -> warning;
_ -> error
- end, "exception on AMQP connection ~p (~s)~n~p~n",
+ end, "closing AMQP connection ~p (~s):~n~p~n",
[self(), ConnStr, Ex])
after
- log(info, "closing AMQP connection ~p (~s)~n", [self(), ConnStr]),
%% We don't close the socket explicitly. The reader is the
%% controlling process and hence its termination will close
%% the socket. Furthermore, gen_tcp:close/1 waits for pending