From c9fa25e8316b8af3e9f11b9e79368092df466972 Mon Sep 17 00:00:00 2001 From: Max Date: Mon, 9 Jan 2017 13:23:15 +0100 Subject: handle_ts1_read(): log sign_link() error Change-Id: I95779ee8590ab16b7af4ad2c79ede68da3a12e5a --- src/input/ipaccess.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/input/ipaccess.c b/src/input/ipaccess.c index 675f07a..9e64471 100644 --- a/src/input/ipaccess.c +++ b/src/input/ipaccess.c @@ -228,7 +228,7 @@ static int handle_ts1_read(struct osmo_fd *bfd) struct e1inp_sign_link *link; struct ipaccess_head *hh; struct msgb *msg = NULL; - int ret; + int ret, rc; ret = ipa_msg_recv_buffered(bfd->fd, &msg, &e1i_ts->pending_msg); if (ret < 0) { @@ -273,13 +273,14 @@ static int handle_ts1_read(struct osmo_fd *bfd) ret = -EINVAL; goto err_msg; } - if (e1i_ts->line->ops->sign_link(msg) < 0) { + rc = e1i_ts->line->ops->sign_link(msg); + if (rc < 0) { /* Don't close the signalling link if the upper layers report * an error, that's too strict. BTW, the signalling layer is * resposible for releasing the message. */ LOGP(DLINP, LOGL_ERROR, "Bad signalling message," - "sign_link returned error\n"); + " sign_link returned error: %s.\n", strerror(-rc)); } return 0; -- cgit v1.2.3