From: Svante Signell Date: Wed, 18 Sep 2013 14:39:09 +0000 (+0200) Subject: gio/gsocket.c: Fix error code checks when SOCK_CLOEXEC is defined but X-Git-Tag: 2.39.0~119 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1d4bb3f5d0e88754aedb04d0a7df0e0c2788e363;p=platform%2Fupstream%2Fglib.git gio/gsocket.c: Fix error code checks when SOCK_CLOEXEC is defined but not supported on GNU/Hurd. https://bugzilla.gnome.org/show_bug.cgi?id=708266 --- diff --git a/gio/gsocket.c b/gio/gsocket.c index 8fcbce4..18e6137 100644 --- a/gio/gsocket.c +++ b/gio/gsocket.c @@ -499,7 +499,7 @@ g_socket (gint domain, return fd; /* It's possible that libc has SOCK_CLOEXEC but the kernel does not */ - if (fd < 0 && errno == EINVAL) + if (fd < 0 && (errno == EINVAL || errno == EPROTOTYPE)) #endif fd = socket (domain, type, protocol);