gsup_test_client: gsupc_read_cb: fix uninitialized value 'io'

Change-Id: Idb3ca50009e25c8e10bcbd15e430caf6de18a040
changes/12/7512/1
Neels Hofmeyr 5 years ago
parent 7fdfad2f5d
commit 053e27528c
  1. 6
      src/libgsupclient/gsup_test_client.c

@ -217,7 +217,7 @@ static int op_type_by_gsup_msgt(enum osmo_gsup_message_type msg_type)
static int gsupc_read_cb(struct gsup_client *gsupc, struct msgb *msg)
{
struct osmo_gsup_message gsup_msg = {0};
struct imsi_op *io;
struct imsi_op *io = NULL;
int rc;
DEBUGP(DLGSUP, "Rx GSUP %s\n", msgb_hexdump(msg));
@ -237,14 +237,14 @@ static int gsupc_read_cb(struct gsup_client *gsupc, struct msgb *msg)
case IMSI_OP_SAI:
case IMSI_OP_LU:
io = imsi_op_find(gsup_msg.imsi, rc);
if (!io)
return -1;
break;
case IMSI_OP_ISD:
/* ISD is an inbound transaction */
io = imsi_op_alloc(g_gc, gsup_msg.imsi, IMSI_OP_ISD);
break;
}
if (!io)
return -1;
imsi_op_rx_gsup(io, &gsup_msg);
msgb_free(msg);

Loading…
Cancel
Save