gdbstub: Fix buffer overflows in gdb_handle_packet()
commit5accecb3a6b49d8ca79684179610583e9c7c1bf5
authorKevin Wolf <kwolf@redhat.com>
Tue, 13 Oct 2015 07:38:50 +0000 (13 09:38 +0200)
committerMichael Tokarev <mjt@tls.msk.ru>
Fri, 6 Nov 2015 12:42:37 +0000 (6 15:42 +0300)
treec25fc582b801c29a2b9ccebb14921cf388eb6433
parent3c15d3a45045de82c744c49ff471d4c7ba405187
gdbstub: Fix buffer overflows in gdb_handle_packet()

Some places in gdb_handle_packet() can get an arbitrary length (most
times directly from the client) and either didn't check it at all or
checked against the wrong value, potentially causing buffer overflows.

Cc: qemu-stable@nongnu.org
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
gdbstub.c