]> sigrok.org Git - libsigrok.git/commitdiff
dmm/bm52x: silence compiler warning related to printf() buffer size
authorGerhard Sittig <redacted>
Tue, 9 Aug 2022 16:05:49 +0000 (18:05 +0200)
committerGerhard Sittig <redacted>
Tue, 9 Aug 2022 16:05:49 +0000 (18:05 +0200)
Increase another text buffer's size to cover the maximum length that an
integer could occupy in theory. Which amends commit 46a36bf0bb2e.

The previous implementation did not suffer from any issue, we know the
number of recordings in the BM52x DMM to remain small. This change only
silences a compiler warning, doesn't change the parser's behaviour.

src/dmm/bm52x.c

index 89c393a92348634423502cb858c50e6ce35612a5..3a4a62b36ce9a4acd7bb40e6d0987ad02cef6977 100644 (file)
@@ -1362,7 +1362,7 @@ SR_PRIV int brymen_bm52x_config_get(void *st, uint32_t key, GVariant **data,
        const struct sr_dev_inst *sdi, const struct sr_channel_group *cg)
 {
        struct brymen_bm52x_state *state;
-       char text[20];
+       char text[32];
 
        state = st;