ipaccess-proxy: Fix two memory leaks
diff --git a/openbsc/src/ipaccess-proxy.c b/openbsc/src/ipaccess-proxy.c
index 6e0ce6a..dd9d6b1 100644
--- a/openbsc/src/ipaccess-proxy.c
+++ b/openbsc/src/ipaccess-proxy.c
@@ -245,7 +245,7 @@
ipbc->id_tags[i] = talloc_size(tall_bsc_ctx, len);
else
#endif
- ipbc->id_tags[i] = talloc_realloc_size(tall_bsc_ctx,
+ ipbc->id_tags[i] = talloc_realloc_size(ipbc,
ipbc->id_tags[i], len);
if (!ipbc->id_tags[i])
return -ENOMEM;
@@ -807,14 +807,11 @@
struct ipa_proxy_conn *ipc = bfd->data;
struct ipa_bts_conn *ipbc = ipc->bts_conn;
struct ipa_proxy_conn *bsc_conn;
- struct msgb *msg = msgb_alloc(PROXY_ALLOC_SIZE, "Abis/IP");
+ struct msgb *msg;
struct ipaccess_head *hh;
int ret = 0;
char *btsbsc;
- if (!msg)
- return -ENOMEM;
-
if ((bfd->priv_nr & 0xff) <= 2)
btsbsc = "BTS";
else