From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43976) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wwuoy-0005hV-V7 for qemu-devel@nongnu.org; Tue, 17 Jun 2014 10:57:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wwuos-0004Qe-Ad for qemu-devel@nongnu.org; Tue, 17 Jun 2014 10:57:12 -0400 Received: from [2001:4b98:dc0:45:216:3eff:fe3d:166f] (port=33151 helo=afflict.kos.to) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wwuos-0004P9-4j for qemu-devel@nongnu.org; Tue, 17 Jun 2014 10:57:06 -0400 From: riku.voipio@linaro.org Date: Tue, 17 Jun 2014 17:56:59 +0300 Message-Id: <480eda2eda7c464e252f17ac87ec61bccc14f285.1403016610.git.riku.voipio@linaro.org> In-Reply-To: References: In-Reply-To: References: Subject: [Qemu-devel] [PULL v2 16/17] linux-user: Return correct errno for unsupported netlink socket List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, Ed Swierk From: Ed Swierk This fixes "Cannot open audit interface - aborting." when the EAFNOSUPPORT errno differs between the target and host architectures (e.g. mips target and x86_64 host). Signed-off-by: Ed Swierk Signed-off-by: Riku Voipio --- 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 840ced1..c134c32 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -1856,7 +1856,7 @@ static abi_long do_socket(int domain, int type, int protocol) } if (domain == PF_NETLINK) - return -EAFNOSUPPORT; /* do not NETLINK socket connections possible */ + return -TARGET_EAFNOSUPPORT; ret = get_errno(socket(domain, type, protocol)); if (ret >= 0) { ret = sock_flags_fixup(ret, target_type); -- 2.0.0.rc2