Commit d00b2618 authored by Isaku Yamahata's avatar Isaku Yamahata Committed by Aurelien Jarno
Browse files

monitor: use after free in do_wav_capture()



use after free in do_wav_capture() on the error path.
Signed-off-by: default avatarIsaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: default avatarAurelien Jarno <aurelien@aurel32.net>
parent 52108a1f
......@@ -2509,8 +2509,9 @@ static void do_wav_capture(Monitor *mon, const QDict *qdict)
nchannels = has_channels ? nchannels : 2;
if (wav_start_capture (s, path, freq, bits, nchannels)) {
monitor_printf(mon, "Faied to add wave capture\n");
monitor_printf(mon, "Failed to add wave capture\n");
qemu_free (s);
return;
}
QLIST_INSERT_HEAD (&capture_head, s, entries);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment