aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-07-27 14:06:21 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2017-08-30 14:12:37 +0200
commit94936254eb2fde284d1c35b2076f4ac305d33f8b (patch)
tree21253bb47a44d04058353b2564e99f2dde180cb9
parent34a313f2e2c60ba061a1515f3a77f9f6f61a413a (diff)
gsup client: move not-connected to error loglevel
-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 258f230c..fd65e7b0 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;