diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2013-01-15 13:48:18 +0100 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2013-01-15 13:48:18 +0100 |
commit | 036b25fb7fccd6bb99f0f539bb42ef6e2155bed2 (patch) | |
tree | fe68a1367588108d61f33f82c790fc123adf1d33 /openbsc/src/osmo-bsc_nat/bsc_nat.c | |
parent | c7de8ef0141c5df73c0fcff976b288e9dfd1f241 (diff) |
nat: Fail if the control interface can not be initialized
Diffstat (limited to 'openbsc/src/osmo-bsc_nat/bsc_nat.c')
-rw-r--r-- | openbsc/src/osmo-bsc_nat/bsc_nat.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/openbsc/src/osmo-bsc_nat/bsc_nat.c b/openbsc/src/osmo-bsc_nat/bsc_nat.c index d5a3a1f3f..dd06a70b6 100644 --- a/openbsc/src/osmo-bsc_nat/bsc_nat.c +++ b/openbsc/src/osmo-bsc_nat/bsc_nat.c @@ -1510,6 +1510,10 @@ int main(int argc, char **argv) } nat->ctrl = bsc_nat_controlif_setup(nat, 4250); + if (!nat->ctrl) { + fprintf(stderr, "Creating the control interface failed.\n"); + exit(1); + } nat->msc_con->connection_loss = msc_connection_was_lost; nat->msc_con->connected = msc_connection_connected; |