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: Use __gettimeofday instead of gettimeofday


Hi,

We should use __gettimeofday instead of gettimeofday for libc internal
use.

H.J.
---
2011-06-23  H.J. Lu  <hongjiu.lu@intel.com>

	* sysdeps/unix/sysv/linux/getsysstats.c (__get_nprocs): Use
	__gettimeofday instead of gettimeofday.

diff --git a/sysdeps/unix/sysv/linux/getsysstats.c b/sysdeps/unix/sysv/linux/getsysstats.c
index b74774f..b9bae3d 100644
--- a/sysdeps/unix/sysv/linux/getsysstats.c
+++ b/sysdeps/unix/sysv/linux/getsysstats.c
@@ -147,7 +147,7 @@ __get_nprocs ()
   INTERNAL_VSYSCALL (clock_gettime, err, 2, CLOCK_REALTIME, &ts);
 #else
   struct timeval ts;
-  gettimeofday (&ts, NULL);
+  __gettimeofday (&ts, NULL);
 #endif
   time_t prev = timestamp;
   atomic_read_barrier ();


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