aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-07-27 14:06:21 +0200
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-08-11 18:34:02 +0200
commit0116c5463b0a1afda36160c3c60d1131e3ad4e50 (patch)
tree79cddd42fec864f2c3a913ef9d9d17cfa69d3a5c /src
parentca50858b90eb6c4c159eee0482eb826ef8c22fb1 (diff)
gsup client: move not-connected to error loglevel
Diffstat (limited to 'src')
-rw-r--r--src/libcommon/gsup_client.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/libcommon/gsup_client.c b/src/libcommon/gsup_client.c
index 258f230cb..fd65e7b0b 100644
--- a/src/libcommon/gsup_client.c
+++ b/src/libcommon/gsup_client.c
@@ -330,20 +330,12 @@ void gsup_client_destroy(struct gsup_client *gsupc)
int gsup_client_send(struct gsup_client *gsupc, struct msgb *msg)
{
- if (!gsupc) {
- LOGP(DGPRS, LOGL_NOTICE, "No GSUP client, unable to "
- "send %s\n", msgb_hexdump(msg));
+ if (!gsupc || !gsupc->is_connected) {
+ LOGP(DGPRS, LOGL_ERROR, "GSUP not connected, unable to send %s\n", msgb_hexdump(msg));
msgb_free(msg);
return -ENOTCONN;
}
- if (!gsupc->is_connected) {
- LOGP(DGPRS, LOGL_NOTICE, "GSUP not connected, unable to "
- "send %s\n", msgb_hexdump(msg));
- msgb_free(msg);
- return -EAGAIN;
- }
-
client_send(gsupc, IPAC_PROTO_EXT_GSUP, msg);
return 0;