diff options
| author | linzhecheng <linzhecheng@huawei.com> | 2018-03-28 21:34:35 +0800 |
|---|---|---|
| committer | Michael S. Tsirkin <mst@redhat.com> | 2018-04-09 17:35:46 +0300 |
| commit | d434e5ac5d70e9da7d20e50246af9251a125bdad (patch) | |
| tree | 52220b1e922e7b615d38b109f820025275c1ec06 /ui/x_keymap.c | |
| parent | e7b94a84b6cb4a632c558ed24e8d6f4baa3f75eb (diff) | |
| download | focaccia-qemu-d434e5ac5d70e9da7d20e50246af9251a125bdad.tar.gz focaccia-qemu-d434e5ac5d70e9da7d20e50246af9251a125bdad.zip | |
virtio-serial: fix heap-over-flow
Check device having the feature of VIRTIO_CONSOLE_F_EMERG_WRITE before get config->emerg_wr. It is neccessary because sizeof(virtio_console_config) is 8 byte if VirtIOSerial doesn't have the feature of VIRTIO_CONSOLE_F_EMERG_WRITE(see virtio_serial_device_realize), read/write emerg_wr will lead to heap-over-flow. Signed-off-by: linzhecheng <linzhecheng@huawei.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'ui/x_keymap.c')
0 files changed, 0 insertions, 0 deletions