vhost: fix malloc size too small
authorDariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Fri, 26 May 2017 11:59:13 +0000 (13:59 +0200)
committerYuanhan Liu <yliu@fridaylinux.org>
Fri, 16 Jun 2017 12:04:25 +0000 (14:04 +0200)
commitd1b2842a9dcf1e7957a185be126f4af9885f9cf7
treeebf8d877e2501e4aeeafdd6ab12274b57b34859b
parent29150b70abf687e1ca4504d06a0b77e66f3207a1
vhost: fix malloc size too small

Amount of allocated memory was too small, causing buffer overflow.

Fixes: eb32247457fe ("vhost: export guest memory regions")
Cc: stable@dpdk.org
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-by: Jens Freimann <jfreiman@redhat.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
lib/librte_vhost/vhost.c