From 9b11e8741d25637b343c8aa8613e69ba7c02d1e4 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Fri, 26 Jun 2009 19:42:28 +0200 Subject: zero-initialize some more memory that we allocate --- openbsc/src/gsm_04_08.c | 2 +- openbsc/src/mncc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'openbsc/src') diff --git a/openbsc/src/gsm_04_08.c b/openbsc/src/gsm_04_08.c index c77268e26..76d748c05 100644 --- a/openbsc/src/gsm_04_08.c +++ b/openbsc/src/gsm_04_08.c @@ -3634,7 +3634,7 @@ static int gsm0408_rcv_cc(struct msgb *msg) DEBUGP(DCC, "Unknown transaction ID %02x, " "creating new trans.\n", transaction_id); /* Create transaction */ - if (!(trans = talloc(tall_trans_ctx, struct gsm_trans))) { + if (!(trans = talloc_zero(tall_trans_ctx, struct gsm_trans))) { DEBUGP(DCC, "No memory for trans.\n"); rc = gsm48_tx_simple(msg->lchan, GSM48_PDISC_CC | transaction_id, diff --git a/openbsc/src/mncc.c b/openbsc/src/mncc.c index 71f2ad501..b2dab078e 100644 --- a/openbsc/src/mncc.c +++ b/openbsc/src/mncc.c @@ -310,7 +310,7 @@ int mncc_recv(struct gsm_network *net, int msg_type, void *arg) tall_call_ctx = talloc_named_const(tall_bsc_ctx, 1, "gsm_call"); /* create call */ - if (!(call = talloc(tall_call_ctx, struct gsm_call))) { + if (!(call = talloc_zero(tall_call_ctx, struct gsm_call))) { struct gsm_mncc rel; memset(&rel, 0, sizeof(struct gsm_mncc)); -- cgit v1.2.3