Pau Espin Pedrol has uploaded this change for review. ( 
https://gerrit.osmocom.org/13482


Change subject: osmo-trx: Check return code of osmo_fd_register
......................................................................

osmo-trx: Check return code of osmo_fd_register

Fixes Coverity CID 197513.
Change-Id: I93fbcb062439a547379aaecba283d107fdc9cb59
---
M Transceiver52M/osmo-trx.cpp
1 file changed, 4 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/82/13482/1

diff --git a/Transceiver52M/osmo-trx.cpp b/Transceiver52M/osmo-trx.cpp
index 88b9de0..b252d0c 100644
--- a/Transceiver52M/osmo-trx.cpp
+++ b/Transceiver52M/osmo-trx.cpp
@@ -237,7 +237,10 @@
        }

        osmo_fd_setup(&signal_ofd, sfd, OSMO_FD_READ, signalfd_callback, NULL, 
0);
-       osmo_fd_register(&signal_ofd);
+       if (osmo_fd_register(&signal_ofd) < 0) {
+               fprintf(stderr, "osmo_fd_register() failed.\n");
+               exit(EXIT_FAILURE);
+       }
 }

 static void print_help()

--
To view, visit https://gerrit.osmocom.org/13482
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I93fbcb062439a547379aaecba283d107fdc9cb59
Gerrit-Change-Number: 13482
Gerrit-PatchSet: 1
Gerrit-Owner: Pau Espin Pedrol <[email protected]>

Reply via email to