qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PULL 17/18] linux-user: Return correct errno for unsupport


From: riku . voipio
Subject: [Qemu-devel] [PULL 17/18] linux-user: Return correct errno for unsupported netlink socket
Date: Mon, 9 Jun 2014 15:46:42 +0300

From: Ed Swierk <address@hidden>

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 <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>
---
 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




reply via email to

[Prev in Thread] Current Thread [Next in Thread]