projects
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c8de6ec
)
qcow2: fix memory leak in qcow2_read_extensions
author
lu zhipeng
<luzhipeng@cestc.cn>
Wed, 21 Sep 2022 14:45:15 +0000
(22:45 +0800)
committer
Kevin Wolf
<kwolf@redhat.com>
Fri, 30 Sep 2022 16:02:30 +0000
(18:02 +0200)
Free feature_table if it is failed in bdrv_pread.
Signed-off-by: lu zhipeng <luzhipeng@cestc.cn>
Message-Id: <
20220921144515
.1166-1-luzhipeng@cestc.cn>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/qcow2.c
patch
|
blob
|
history
diff --git
a/block/qcow2.c
b/block/qcow2.c
index c6c6692fb7f2f1e731a62be683c767d574a1975f..c8fc3a6160ef294780070774a666d75c83cb35f7 100644
(file)
--- a/
block/qcow2.c
+++ b/
block/qcow2.c
@@
-275,6
+275,7
@@
static int qcow2_read_extensions(BlockDriverState *bs, uint64_t start_offset,
if (ret < 0) {
error_setg_errno(errp, -ret, "ERROR: ext_feature_table: "
"Could not read table");
+ g_free(feature_table);
return ret;
}