summaryrefslogtreecommitdiffstats
path: root/proto/bgp/bgp.c
diff options
context:
space:
mode:
Diffstat (limited to 'proto/bgp/bgp.c')
-rw-r--r--proto/bgp/bgp.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/proto/bgp/bgp.c b/proto/bgp/bgp.c
index 4a68f04..41081f2 100644
--- a/proto/bgp/bgp.c
+++ b/proto/bgp/bgp.c
@@ -158,7 +158,10 @@ bgp_sock_err(sock *sk, int err)
struct bgp_conn *conn = sk->data;
struct bgp_proto *p = conn->bgp;
- BGP_TRACE(D_EVENTS, "Connection closed (socket error %d)", err);
+ if (err)
+ BGP_TRACE(D_EVENTS, "Connection lost (%M)", err);
+ else
+ BGP_TRACE(D_EVENTS, "Connection closed");
switch (conn->state)
{
case BS_CONNECT: