|
From: | Riku Voipio |
Subject: | Re: [Qemu-devel] [PATCH 01/34] linux-user: Fix array bounds in errno conversion |
Date: | Mon, 12 Oct 2015 16:42:12 +0300 |
User-agent: | Trojita/0.5-git; Qt/5.4.2; xcb; Linux; Debian GNU/Linux testing (stretch) |
On perjantaina 11. syyskuuta 2015 13.59.29 EEST, Peter Maydell wrote:
On 6 September 2015 at 00:56, Timothy E Baldwin <address@hidden> wrote:Check array bounds in host_to_target_errno() and target_to_host_errno(). Signed-off-by: Timothy Edward Baldwin <address@hidden> --- linux-user/syscall.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ...Maybe we should also check that the passed in error value is not negative? (Given the errno-is-positive/syscall-return-negative conventions, it's an easy mistake to make...)
I've applied a version of this patch that implements this by setting the function argument to unsigned
Riku
[Prev in Thread] | Current Thread | [Next in Thread] |