This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH,HURD] socket: fix errno code


Hi,

attached there is a small patch to fix the errno value for the "protocol 
not supported" case, from the non-standard EPFNOSUPPORT to EAFNOSUPPORT.

Thanks,
-- 
Pino Toscano
2012-01-22  Pino Toscano  <toscano.pino@tiscali.it>

	* sysdeps/mach/hurd/socket.c (__socket): Return EAFNOSUPPORT instead
	of the non-standard EPFNOSUPPORT.
--- a/sysdeps/mach/hurd/socket.c
+++ b/sysdeps/mach/hurd/socket.c
@@ -57,7 +57,7 @@ __socket (domain, type, protocol)
      isn't supported.  */
   if (err == MACH_SEND_INVALID_DEST || err == MIG_SERVER_DIED
       || err == MIG_BAD_ID || err == EOPNOTSUPP)
-    err = EPFNOSUPPORT;
+    err = EAFNOSUPPORT;
 
   if (err)
     return __hurd_fail (err);

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]