Re: [PATCH] block: m25p80: Fix heap-buffer-overflow in flash_erase function

2024-06-19 Thread Zheyu Ma
Hi Philippe, On Tue, Jun 18, 2024 at 10:34 PM Philippe Mathieu-Daudé wrote: > On 18/6/24 21:11, Zheyu Ma wrote: > > Thanks for your useful advice! > > > > So how about report the issue and return: > > We might report the issue to the user, but there should >

Re: [PATCH] block: m25p80: Fix heap-buffer-overflow in flash_erase function

2024-06-18 Thread Zheyu Ma
_assert) != capa_to_assert) { regards, Zheyu On Tue, Jun 18, 2024 at 5:35 PM Philippe Mathieu-Daudé wrote: > Hi Zheyu, > > On 18/6/24 17:23, Zheyu Ma wrote: > > This patch fixes a heap-buffer-overflow issue in the flash_erase function > > of the m25p80 flash memory emulatio

[PATCH] block: m25p80: Fix heap-buffer-overflow in flash_erase function

2024-06-18 Thread Zheyu Ma
e8be4b in npcm7xx_fiu_ctrl_write hw/ssi/npcm7xx_fiu.c:428:13 Signed-off-by: Zheyu Ma --- hw/block/m25p80.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index 8dec134832..e9a59f6616 100644 --- a/hw/block/m25p80.c +++ b/hw/block/m25p80.c @@ -617,6 +617,12 @@ stati

[PATCH] block/virtio-blk: Fix memory leak from virtio_blk_zone_report

2024-04-04 Thread Zheyu Ma
:1157:5 Signed-off-by: Zheyu Ma --- hw/block/virtio-blk.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index 92de315f17..bb86e65f65 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -768,7 +768,8 @@ static void