[M] Change in libosmocore[master]: tests: Add initial osmo_io tests
Attention is currently required from: fixeria, pespin, daniel. laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/32181 ) Change subject: tests: Add initial osmo_io tests ...................................................................... Patch Set 13: Code-Review+1 (2 comments) File tests/osmo_io/osmo_io_test.c: https://gerrit.osmocom.org/c/libosmocore/+/32181/comment/46d61c5c_720ce9a2 PS3, Line 54: printf("%s: Write returned rc=%d\n", osmo_iofd_get_name(iofd), rc);
Correct. […] yes, passing the msg to the write_cb is the right thing to do. Not sure whether 'const' is a good idea. After all, the call-back could also free a 'const' msgb and it would be just as much as an error. Also, it is perfectly legal for the call-back to modify the msgb at that point (for example to zero some kind of "secret" value (password, crypto key or whatever) which they don't want to retain in memory even of something that's returned to the talloc pool automatically a few nanoseconds later.
File tests/osmo_io/osmo_io_test.c: https://gerrit.osmocom.org/c/libosmocore/+/32181/comment/9b2ad388_4f6f3dc8 PS9, Line 95: for (int i = 0; i < 128; i++)
I would like to keep those as is tbh. […] Ack
-- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/32181 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: Ia67629e53f4d2e5784177250d58e268fdfcaa0c2 Gerrit-Change-Number: 32181 Gerrit-PatchSet: 13 Gerrit-Owner: daniel <dwillmann@sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de> Gerrit-Reviewer: laforge <laforge@osmocom.org> Gerrit-CC: pespin <pespin@sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy@sysmocom.de> Gerrit-Attention: pespin <pespin@sysmocom.de> Gerrit-Attention: daniel <dwillmann@sysmocom.de> Gerrit-Comment-Date: Tue, 09 May 2023 23:24:53 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Comment-In-Reply-To: pespin <pespin@sysmocom.de> Comment-In-Reply-To: fixeria <vyanitskiy@sysmocom.de> Comment-In-Reply-To: daniel <dwillmann@sysmocom.de> Gerrit-MessageType: comment
participants (1)
-
laforge