diff options
Diffstat (limited to 'src/osmo-bts-sysmo/main.c')
-rw-r--r-- | src/osmo-bts-sysmo/main.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/osmo-bts-sysmo/main.c b/src/osmo-bts-sysmo/main.c index bd6a1818..797f1741 100644 --- a/src/osmo-bts-sysmo/main.c +++ b/src/osmo-bts-sysmo/main.c @@ -317,7 +317,16 @@ static int read_sock(struct osmo_fd *fd, unsigned int what) msgb_put(msg, rc); - if (check_oml_msg(msg) < 0) { + rc = check_ipa_header(msg); + if (rc < 0) { + LOGP(DL1C, LOGL_ERROR, "Malformed receive message: Ipa hdr\n"); + goto err; + } + + msgb_pull(msg, sizeof(struct ipaccess_head)); + + rc = check_oml_msg(msg); + if (rc < 0) { LOGP(DL1C, LOGL_ERROR, "Malformed receive message\n"); goto err; } |