qemu-sockets: Fix buffer overflow in inet_parse()
authorKevin Wolf <kwolf@redhat.com>
Fri, 30 Jan 2015 19:37:55 +0000 (20:37 +0100)
committerMichael Tokarev <mjt@tls.msk.ru>
Tue, 10 Feb 2015 06:27:20 +0000 (09:27 +0300)
commit55a10996034cb2e633f0437cedd97f345183c0ec
tree27dc6f669c1ed3af7a56fa026a05b659fa5ee114
parent02f292d9051f616511f482275b571c6153e3a48b
qemu-sockets: Fix buffer overflow in inet_parse()

The size of the stack allocated host[] array didn't account for the
terminating '\0' byte that sscanf() writes. Fix the array size.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
util/qemu-sockets.c