summaryrefslogtreecommitdiffstats
path: root/openbsc
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2010-05-19 15:46:49 +0200
committerHarald Welte <laforge@gnumonks.org>2010-05-19 15:46:49 +0200
commitb11226d77aa17bcc00177a7fcfddf9569db544fc (patch)
treec790aa30609f09dec4e95e09642adc01e9708bd8 /openbsc
parentba4c666a9f50efeaabb546629de320bdeb134500 (diff)
[GPRS] NS/FR/GRE rcvmsg case: msgb_free() in error case
Diffstat (limited to 'openbsc')
-rw-r--r--openbsc/src/gprs/gprs_ns_frgre.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/openbsc/src/gprs/gprs_ns_frgre.c b/openbsc/src/gprs/gprs_ns_frgre.c
index 7367b6a6..359c0f71 100644
--- a/openbsc/src/gprs/gprs_ns_frgre.c
+++ b/openbsc/src/gprs/gprs_ns_frgre.c
@@ -67,11 +67,10 @@ static struct msgb *read_nsfrgre_msg(struct bsc_fd *bfd, int *error,
LOGP(DNS, LOGL_ERROR, "recv error %s during NS-FR-GRE recv\n",
strerror(errno));
*error = ret;
- return NULL;
+ goto out_err;
} else if (ret == 0) {
- msgb_free(msg);
*error = ret;
- return NULL;
+ goto out_err;
}
msgb_put(msg, ret);