bsd-user: Suppress gcc 4.x -Wpointer-sign (included in -Wall) warning

This is the same change as b55266b5 in linux-user.

Signed-off-by: Ed Maste <emaste@freebsd.org>
Message-id: 1459867593-72017-1-git-send-email-emaste@freebsd.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
Ed Maste 2016-04-05 10:46:33 -04:00 committed by Peter Maydell
parent abd4556a17
commit 43b0ea1a41
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ abi_long target_strlen(abi_ulong guest_addr1)
ptr = lock_user(VERIFY_READ, guest_addr, max_len, 1);
if (!ptr)
return -TARGET_EFAULT;
len = qemu_strnlen((char *)ptr, max_len);
len = qemu_strnlen((const char *)ptr, max_len);
unlock_user(ptr, guest_addr, 0);
guest_addr += len;
/* we don't allow wrapping or integer overflow */