Attention is currently required from: laforge, daniel, lynxis lazus. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/30936 ) Change subject: gpsr_ns2_udp: Use osmo_io_fd instead of osmo_fd ...................................................................... Patch Set 7: (4 comments) File src/gb/gprs_ns2_udp.c: https://gerrit.osmocom.org/c/libosmocore/+/30936/comment/ba16a572_be039c3f PS4, Line 183: struct osmo_sockaddr *saddr)
wrong indentation Done
https://gerrit.osmocom.org/c/libosmocore/+/30936/comment/b4638660_a5c6cf04 PS4, Line 225: static void handle_nsip_sendmsg(struct osmo_io_fd *iofd, int res, struct msgb *msg)
if this is not needed, then pass a NULL pointer instead of this function? Answering myself here: the library code unconditionally calls the callback function, because the app is expected to want to have a callback set to be able to check the return code of the write operation done by the library (available in "res" param here).
https://gerrit.osmocom.org/c/libosmocore/+/30936/comment/7ece2bf4_66e9701e PS4, Line 272: .sendmsg_cb = &handle_nsip_sendmsg,
= NULL See my other comment.
File src/gb/gprs_ns2_udp.c: https://gerrit.osmocom.org/c/libosmocore/+/30936/comment/1143b62d_f688cba3 PS6, Line 72: if (priv->iofd) : osmo_iofd_free(priv->iofd);
ACK, in the new patchset osmo_iofd_free() can handle a call with NULL. I'm adding this NULL check myself in the new version of the other patch I'm submitting now.
-- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/30936 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: Id776d2d9f35c304620f3d5b94492148dd987f5a0 Gerrit-Change-Number: 30936 Gerrit-PatchSet: 7 Gerrit-Owner: daniel <dwillmann@sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: lynxis lazus <lynxis@fe80.eu> Gerrit-CC: laforge <laforge@osmocom.org> Gerrit-CC: pespin <pespin@sysmocom.de> Gerrit-Attention: laforge <laforge@osmocom.org> Gerrit-Attention: daniel <dwillmann@sysmocom.de> Gerrit-Attention: lynxis lazus <lynxis@fe80.eu> Gerrit-Comment-Date: Thu, 27 Apr 2023 13:24:03 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: laforge <laforge@osmocom.org> Comment-In-Reply-To: pespin <pespin@sysmocom.de> Comment-In-Reply-To: daniel <dwillmann@sysmocom.de> Gerrit-MessageType: comment