This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Harald Welte gerrit-no-reply at lists.osmocom.orgReview at https://gerrit.osmocom.org/1331 rs232-write: Check return value of osmo_fd_register() Change-Id: If40e85600ca1dfbda5975d7aa92cccdb11f9c34d Fixes: Coverity CID 57632 --- M examples/rs232-write.c 1 file changed, 6 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/31/1331/1 diff --git a/examples/rs232-write.c b/examples/rs232-write.c index 11498f3..d5aee68 100644 --- a/examples/rs232-write.c +++ b/examples/rs232-write.c @@ -347,6 +347,7 @@ int main(void) { struct osmo_fd *kbd_ofd; + int rc; tall_test = talloc_named_const(NULL, 1, "osmo_rs232_test"); @@ -379,7 +380,11 @@ kbd_ofd->when = BSC_FD_READ; kbd_ofd->data = NULL; kbd_ofd->cb = kbd_cb; - osmo_fd_register(kbd_ofd); + rc = osmo_fd_register(kbd_ofd); + if (rc < 0) { + LOGP(DRS232TEST, LOGL_ERROR, "FD Register\n"); + exit(EXIT_FAILURE); + } while(1) { osmo_select_main(0); -- To view, visit https://gerrit.osmocom.org/1331 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If40e85600ca1dfbda5975d7aa92cccdb11f9c34d Gerrit-PatchSet: 1 Gerrit-Project: libosmo-netif Gerrit-Branch: master Gerrit-Owner: Harald Welte <laforge at gnumonks.org>