]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Fix SOCK_CLOEXEC for accept4
authorCarlos O'Donell <carlos@systemhalted.org>
Mon, 1 Feb 2010 22:52:33 +0000 (17:52 -0500)
committerCarlos O'Donell <carlos@systemhalted.org>
Mon, 1 Feb 2010 22:55:00 +0000 (17:55 -0500)
Adjust the value of SOCK_CLOEXEC to match the kernel
value used for accept4. This has never worked in the
past, and all old applications are broken, therefore
we change this value to match the kernel value.

ChangeLog.hppa
sysdeps/unix/sysv/linux/hppa/bits/socket.h

index 4ccc1df435e64a72b818c22176a736ce152d709b..28a3c44e72e4cdca62ece9d1c84f849df37dd9ba 100644 (file)
@@ -1,3 +1,8 @@
+2010-02-01  Kyle McMartin  <kyle@redhat.com>
+
+       * sysdeps/unix/sysv/linux/hppa/bits/socket.h: Fix value of
+       SOCK_CLOEXEC to match O_CLOEXEC.
+
 2010-02-01  Carlos O'Donell  <carlos@codesourcery.com>
 
        * sysdeps/unix/sysv/linux/hppa/Versions: Bump
index ac6e81b0ff5d0b6228f05389e6af7baef74a611d..bcc27ccc6f7fc0bcc3d4e02864a8df64537f95d2 100644 (file)
@@ -1,6 +1,6 @@
 /* System-specific socket constants and types.  Linux version.
-   Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007, 2008, 2009
-   Free Software Foundation, Inc.
+   Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007, 2008, 2009,
+   2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -62,7 +62,7 @@ enum __socket_type
   /* Flags to be ORed into the type parameter of socket and socketpair and
      used for the flags parameter of paccept.  */
 
-  SOCK_CLOEXEC = 02000000,     /* Atomically set close-on-exec flag for the
+  SOCK_CLOEXEC = 01000000,     /* Atomically set close-on-exec flag for the
                                   new descriptor(s).  */
 #define SOCK_CLOEXEC SOCK_CLOEXEC
 #undef SOCK_NONBLOCK