Received: from eggs.gnu.org ([2001:4830:134:3::10]:58848) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W3qxr-0008PC-6k for qemu-devel@nongnu.org; Thu, 16 Jan 2014 12:42:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W3qxj-0000xh-Pw for qemu-devel@nongnu.org; Thu, 16 Jan 2014 12:42:47 -0500 From: Michael Tokarev Date: Thu, 16 Jan 2014 21:35:17 +0400 Message-Id: <1389893719-16336-10-git-send-email-mjt@msgid.tls.msk.ru> In-Reply-To: <1389893719-16336-1-git-send-email-mjt@msgid.tls.msk.ru> References: <1389893719-16336-1-git-send-email-mjt@msgid.tls.msk.ru> Subject: [Qemu-devel] [PULL 09/11] linux-user: fixed recvfrom() addrlen List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: aliguori@amazon.com Cc: qemu-trivial@nongnu.org, Michael Tokarev , Pavel Zbitskiy , qemu-devel@nongnu.org From: Pavel Zbitskiy addrlen parameter of recvfrom() of type socklen_t* was read into variable of type socklen_t, that caused zeroing out of upper 4 bytes when running s390x on top of x86_64. This patch changes addrlen type to abi_ulong. Signed-off-by: Pavel Zbitskiy Signed-off-by: Michael Tokarev --- linux-user/syscall.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index a9ce6ba..bc0ac98 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -2340,7 +2340,7 @@ static abi_long do_socketcall(int num, abi_ulong vptr) size_t len; abi_ulong flags; abi_ulong addr; - socklen_t addrlen; + abi_ulong addrlen; if (get_user_ual(sockfd, vptr) || get_user_ual(msg, vptr + n) -- 1.7.10.4