sgsnemu: Free strings in error path

In create_pdp_conf(), we have to free() any strings both in the
success and in the error case.

Change-Id: If59cc8d6d151c123f46c1d029091209fd82b3c8e
Fixes: Coverity CID#187636, CID#187633
This commit is contained in:
Harald Welte 2017-11-06 03:09:35 +09:00
parent b11ed0f132
commit b589e78f13
1 changed files with 2 additions and 2 deletions

View File

@ -1459,9 +1459,9 @@ static int create_pdp_conf(struct pdp_t *pdp, void *cbp, int cause)
"router advertisements; SLAAC will not suceed, please "
"fix your setup!\n");
}
free(accept_ra);
free(forwarding);
}
free(accept_ra);
free(forwarding);
}
ipset((struct iphash_t *)pdp->peer, &addr);