summaryrefslogtreecommitdiff
path: root/test/cmd
diff options
context:
space:
mode:
authorHeinrich Schuchardt <[email protected]>2024-11-02 16:41:30 +0100
committerTom Rini <[email protected]>2024-11-14 18:14:06 -0600
commitd8c5bcbd224fddd983f0796886409ede880d11ac (patch)
tree9c93e6cda220c078ab3cc08b707ea337e64f8501 /test/cmd
parentb891826067c2d51cdb0f46b3763642bf8484ebb8 (diff)
test: cmd/mbr: pass correct buffer size to init_write_buffers
We want to completely initialize the mbr and embr buffers. This requires passing the buffer size and not the size of a pointer to the buffer. Addresses-Coverity-ID: 510454 Wrong sizeof argument Signed-off-by: Heinrich Schuchardt <[email protected]>
Diffstat (limited to 'test/cmd')
-rw-r--r--test/cmd/mbr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/cmd/mbr.c b/test/cmd/mbr.c
index b14137e589a..16a8bc39e7e 100644
--- a/test/cmd/mbr.c
+++ b/test/cmd/mbr.c
@@ -277,7 +277,7 @@ static int mbr_test_run(struct unit_test_state *uts)
(ulong)0xbffe00 / BLKSZ));
/* Test one MBR partition */
- init_write_buffers(mbr_wbuf, sizeof(mbr_wbuf), ebr_wbuf, sizeof(ebr_wbuf), __LINE__);
+ init_write_buffers(mbr_wbuf, BLKSZ, ebr_wbuf, BLKSZ, __LINE__);
ut_assertok(build_mbr_parts(mbr_parts_buf, sizeof(mbr_parts_buf), 1));
ut_assertok(run_commandf("write mmc 6:0 %lx 0 1", mbr_wa));
memset(rbuf, '\0', BLKSZ);