]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Mon, 4 Oct 2004 16:35:54 +0000 (16:35 +0000)
committerUlrich Drepper <drepper@redhat.com>
Mon, 4 Oct 2004 16:35:54 +0000 (16:35 +0000)
* nscd/connections.c (start_threads): Use sysconf in case
_POSIX_CLOCK_SELECTION or _POSIX_MONOTONIC_CLOCK is not greater zero.

* nscd/nscd.c: Remove getaddrinfo stub definition.

ChangeLog
linuxthreads/ChangeLog
linuxthreads/sysdeps/unix/sysv/linux/bits/posix_opt.h
linuxthreads/sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
linuxthreads/sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h
linuxthreads/sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h
nscd/connections.c
nscd/nscd.c

index e2a2088ed7c37e966ccefe5c0c328ce5405a12a3..da2bcc5cd0c18818068f82c8654d1b12b334d267 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,11 @@
 2004-10-04  Ulrich Drepper  <drepper@redhat.com>
 
+       * nscd/connections.c (start_threads): Use sysconf in case
+       _POSIX_CLOCK_SELECTION or _POSIX_MONOTONIC_CLOCK is not greater zero.
+
        * nscd/Makefile (nscd-modules): Add gai.
        * nscd/gai.c: New file.
+       * nscd/nscd.c: Remove getaddrinfo stub definition.
 
        * assert/assert.h: Give up on using __builtin_expect.
 
index 6f95f03462ae0debb1d49ab8b1b0f5b7ea20098f..35debfa020d4c030121b63eeef8f5d9aa8677a30 100644 (file)
@@ -1,3 +1,11 @@
+2004-10-04  Ulrich Drepper  <drepper@redhat.com>
+
+       * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
+       _POSIX_THREAD_PROCESS_SHARED and _POSIX_CLOCK_SELECTION as -1.
+       * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
+       * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
+       * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
+
 2004-09-25  Roland McGrath  <roland@redhat.com>
 
        [BZ #406]
index 06fd0a29b2555c766d3f0129e3612b5267634715..1a0f4e01428224b462eeea533f0fd1e6737606fa 100644 (file)
 /* POSIX message queues are available.  */
 #define        _POSIX_MESSAGE_PASSING  200112L
 
+/* Thread process-shared synchronization is not supported.  */
+#define _POSIX_THREAD_PROCESS_SHARED   -1
+
 /* The monotonic clock might be available.  */
 #define _POSIX_MONOTONIC_CLOCK 0
 
+/* The clock selection interfaces are not available.  */
+#define _POSIX_CLOCK_SELECTION -1
+
 #endif /* posix_opt.h */
index 18a840ed98e8bd3f6f3c3fda280232cfdcc1efcb..7a4aa8011eba9b918220becdb3631a4147633355 100644 (file)
 /* POSIX message queues are available.  */
 #define        _POSIX_MESSAGE_PASSING  200112L
 
+/* Thread process-shared synchronization is not supported.  */
+#define _POSIX_THREAD_PROCESS_SHARED   -1
+
 /* The monotonic clock might be available.  */
 #define _POSIX_MONOTONIC_CLOCK 0
 
+/* The clock selection interfaces are not available.  */
+#define _POSIX_CLOCK_SELECTION -1
+
 #endif /* posix_opt.h */
index 07780df9c13c3934997c57e69566fd44db4f2295..0d7d73c78f0e2e641de7a6a190dab7176dd302f6 100644 (file)
 /* POSIX message queues are available.  */
 #define        _POSIX_MESSAGE_PASSING  200112L
 
+/* Thread process-shared synchronization is not supported.  */
+#define _POSIX_THREAD_PROCESS_SHARED   -1
+
 /* The monotonic clock might be available.  */
 #define _POSIX_MONOTONIC_CLOCK 0
 
+/* The clock selection interfaces are not available.  */
+#define _POSIX_CLOCK_SELECTION -1
+
 #endif /* posix_opt.h */
index 3a5fc7a1e19c266e3c5709e1beff097be3de4db4..b45d121f64e0ca46ba06bf8cbfff16b638b7a152 100644 (file)
 /* POSIX message queues are available.  */
 #define        _POSIX_MESSAGE_PASSING  200112L
 
+/* Thread process-shared synchronization is not supported.  */
+#define _POSIX_THREAD_PROCESS_SHARED   -1
+
 /* The monotonic clock might be available.  */
 #define _POSIX_MONOTONIC_CLOCK 0
 
+/* The clock selection interfaces are not available.  */
+#define _POSIX_CLOCK_SELECTION -1
+
 #endif /* posix_opt.h */
index 45042beaab32c1e30acb3d3033469d9596db5e50..aae798ed47cf0fd66c071126ab96fa42b6c2fc5f 100644 (file)
@@ -1455,10 +1455,18 @@ start_threads (void)
   pthread_condattr_t condattr;
   pthread_condattr_init (&condattr);
 
-#if _POSIX_CLOCK_SELECTION >= 0 && _POSIX_MONOTONIC_CLOCK >= 0
+#if defined _POSIX_CLOCK_SELECTION && _POSIX_CLOCK_SELECTION >= 0 \
+    && defined _POSIX_MONOTONIC_CLOCK && _POSIX_MONOTONIC_CLOCK >= 0
   /* Determine whether the monotonous clock is available.  */
   struct timespec dummy;
-  if (clock_getres (CLOCK_MONOTONIC, &dummy) == 0
+  if (
+# if _POSIX_MONOTONIC_CLOCK == 0
+      sysconf (_SC_MONOTONIC_CLOCK) > 0 &&
+# endif
+# if _POSIX_CLOCK_SELECTION == 0
+      sysconf (_SC_CLOCK_SELECTION) > 0 &&
+# endif
+      clock_getres (CLOCK_MONOTONIC, &dummy) == 0
       && pthread_condattr_setclock (&condattr, CLOCK_MONOTONIC) == 0)
     timeout_clock = CLOCK_MONOTONIC;
 #endif
index 0ef54bcf081860ce12aeae64c9c09426aa49ccb6..0cc1818d9d80283a9bbc578ed15845e7258d30b2 100644 (file)
@@ -502,16 +502,3 @@ write_pid (const char *file)
 
   return 0;
 }
-
-
-/* This is an ugly hack which prevents getaddrinfo from being dragged
-   into nscd.  There currently is no special getaddrinfo version for
-   use in nscd.  In case it should be necessary such a version must be
-   created and this dummy version should be removed.  */
-extern void getaddrinfo (void) __attribute ((visibility ("hidden")));
-
-void
-getaddrinfo (void)
-{
-  abort ();
-}