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/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/25656 ) Change subject: fix rsl_chan_nr_str_{buf,c}(): enlarge the buffer size ...................................................................... fix rsl_chan_nr_str_{buf,c}(): enlarge the buffer size 20 bytes is not enough for some VAMOS specific channel number values, so the resulting string representation gets truncated by snprintf(): expected: "VAMOS TCH/H(0) on TS4\0" actual: "VAMOS TCH/H(0) on T\0" Let's enlarge the buffers to 32 bytes. Change-Id: I68d839f4ab742cf56de34e7e22572a1163aec2da --- M src/gsm/rsl.c 1 file changed, 3 insertions(+), 3 deletions(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve laforge: Looks good to me, approved diff --git a/src/gsm/rsl.c b/src/gsm/rsl.c index 0574966..e648d82 100644 --- a/src/gsm/rsl.c +++ b/src/gsm/rsl.c @@ -268,7 +268,7 @@ */ const char *rsl_chan_nr_str(uint8_t chan_nr) { - static __thread char str[20]; + static __thread char str[32]; return rsl_chan_nr_str_buf(str, sizeof(str), chan_nr); } @@ -279,10 +279,10 @@ */ char *rsl_chan_nr_str_c(const void *ctx, uint8_t chan_nr) { - char *str = talloc_size(ctx, 20); + char *str = talloc_size(ctx, 32); if (!str) return NULL; - return rsl_chan_nr_str_buf(str, 20, chan_nr); + return rsl_chan_nr_str_buf(str, 32, chan_nr); } static const struct value_string rsl_err_vals[] = { -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/25656 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I68d839f4ab742cf56de34e7e22572a1163aec2da Gerrit-Change-Number: 25656 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de> Gerrit-Reviewer: pespin <pespin at sysmocom.de> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20211002/bd02125d/attachment.htm>