Skip to content

Commit aa6c645

Browse files
committed
test(app_format): fixed buffer overflow in esp_app_format test
1 parent 97ae78e commit aa6c645

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

components/esp_app_format/test_apps/main/test_app_desc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ TEST(esp_app_format, esp_app_get_elf_sha256_test)
2929
int res;
3030
size_t len;
3131

32-
char ref_sha256[sha256_hex_len + 1];
32+
char ref_sha256[sha256_hex_len + 2];
3333
const esp_app_desc_t* desc = esp_app_get_description();
3434
for (int i = 0; i < sizeof(ref_sha256) / 2; ++i) {
3535
snprintf(ref_sha256 + 2 * i, 3, "%02x", desc->app_elf_sha256[i]);

0 commit comments

Comments
 (0)