Skip to content

Commit

Permalink
Fix buffer overflow in tests when using a large block size
Browse files Browse the repository at this point in the history
  • Loading branch information
kaetemi committed Jul 9, 2022
1 parent 40dba4a commit 9af63b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
__attribute__((unused)) lfs_dir_t dir;
__attribute__((unused)) struct lfs_info info;
__attribute__((unused)) char path[1024];
__attribute__((unused)) uint8_t buffer[1024];
__attribute__((unused)) uint8_t buffer[(1024 > LFS_BLOCK_SIZE * 4) ? (1024) : (LFS_BLOCK_SIZE * 4)];
__attribute__((unused)) lfs_size_t size;
__attribute__((unused)) int err;
Expand Down

0 comments on commit 9af63b3

Please # to comment.