Skip to content

Commit 418c47c

Browse files
committed
kv: fit string (including null) into given buffer
The old initializer implicitly truncated the null terminator of the string, which is now a warning/error.
1 parent bbb2dee commit 418c47c

File tree

1 file changed

+1
-1
lines changed
  • examples/tests/kv/kv_system

1 file changed

+1
-1
lines changed

examples/tests/kv/kv_system/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#define DATA_LEN 32
99

1010
uint8_t key_buf[KEY_LEN] = "First Key";
11-
uint8_t data_buf[DATA_LEN] = "My secret key, that no one knows";
11+
uint8_t data_buf[DATA_LEN] = "My secret key that no one knows";
1212
uint8_t out_buf[DATA_LEN] = "Just junk";
1313

1414
static void kv_cb(int result,

0 commit comments

Comments
 (0)