From fbbc73b3d7fc1c1f4aa8c7f8d30ced6778c50506 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Wed, 2 Aug 2006 00:08:03 +0000 Subject: * nscd/initgrcache.c (addinitgroupsX): Judge successful lookups by status of NSS calls, not the number of returned entries. --- nptl/sysdeps/unix/sysv/linux/i386/smp.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'nptl') diff --git a/nptl/sysdeps/unix/sysv/linux/i386/smp.h b/nptl/sysdeps/unix/sysv/linux/i386/smp.h index cb24c9e177..f68a0c0758 100644 --- a/nptl/sysdeps/unix/sysv/linux/i386/smp.h +++ b/nptl/sysdeps/unix/sysv/linux/i386/smp.h @@ -31,25 +31,25 @@ is_smp_system (void) { union { - struct utsname uts; + struct utsname uts; char buf[512]; - }; + } u; char *cp; /* Try reading the number using `sysctl' first. */ - if (uname (&uts) == 0) - cp = uts.version; + if (uname (&u.uts) == 0) + cp = u.uts.version; else { /* This was not successful. Now try reading the /proc filesystem. */ int fd = open_not_cancel_2 ("/proc/sys/kernel/version", O_RDONLY); if (__builtin_expect (fd, 0) == -1 - || (reslen = read_not_cancel (fd, buf, sizeof (buf))) <= 0) + || read_not_cancel (fd, u.buf, sizeof (u.buf)) <= 0) /* This also didn't work. We give up and say it's a UP machine. */ - buf[0] = '\0'; + u.buf[0] = '\0'; close_not_cancel_no_status (fd); - cp = buf; + cp = u.buf; } return strstr (cp, "SMP") != NULL; -- cgit v1.2.3