]> git.proxmox.com Git - qemu.git/commit
linux-user: make bogus negative iovec lengths fail EINVAL
authorPeter Maydell <peter.maydell@linaro.org>
Fri, 8 Feb 2013 07:58:41 +0000 (07:58 +0000)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Tue, 2 Apr 2013 21:23:52 +0000 (16:23 -0500)
commit8378910554a03d54c22ab46cfaec491ee95b8315
treef5f5de5c0482ae78dede758e71af0106b7ec3282
parent7a238b9fbdd0f4d21e8b1d5825067f92c394449c
linux-user: make bogus negative iovec lengths fail EINVAL

If the guest passes us a bogus negative length for an iovec, fail
EINVAL rather than proceeding blindly forward. This fixes some of
the error cases tests for readv and writev in the LTP.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
(cherry picked from commit dfae8e00f8ddeedcda24bd28f71d4fd2a9f988b8)

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
linux-user/syscall.c