diff options
author | Daniel Willmann <daniel@totalueberwachung.de> | 2011-08-05 12:22:35 +0200 |
---|---|---|
committer | Daniel Willmann <daniel@totalueberwachung.de> | 2011-08-22 19:27:49 +0200 |
commit | 40f917f3a6dc7d801192b9c8d8cb849fe54923ef (patch) | |
tree | 4d40927acd34f6f4e28465add793a6bb77b88c07 /openbsc/src/osmo-nitb | |
parent | 5c5bfc4e3cdf98101ac6cf1094649bebee01fcac (diff) |
libctrl: Improve error handling if controlif setup fails
Diffstat (limited to 'openbsc/src/osmo-nitb')
-rw-r--r-- | openbsc/src/osmo-nitb/bsc_hack.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/openbsc/src/osmo-nitb/bsc_hack.c b/openbsc/src/osmo-nitb/bsc_hack.c index 724e97344..7135455ab 100644 --- a/openbsc/src/osmo-nitb/bsc_hack.c +++ b/openbsc/src/osmo-nitb/bsc_hack.c @@ -251,6 +251,11 @@ int main(int argc, char **argv) bsc_api_init(bsc_gsmnet, msc_bsc_api()); bsc_gsmnet->ctrl = controlif_setup(bsc_gsmnet, 4249); + if (!bsc_gsmnet->ctrl) { + printf("Failed to initialize control interface. Exiting.\n"); + return -1; + } + /* seed the PRNG */ srand(time(NULL)); |