alpha: Avoid unused variable warnings with INTERNAL_SYSCALL_ERR*.
authorRichard Henderson <rth@twiddle.net>
Fri, 26 Mar 2010 17:29:42 +0000 (10:29 -0700)
committerRichard Henderson <rth@twiddle.net>
Fri, 26 Mar 2010 20:17:52 +0000 (13:17 -0700)
Signed-off-by: Richard Henderson <rth@twiddle.net>
ChangeLog.alpha
sysdeps/unix/alpha/sysdep.h

index 78ce863..e4c4a6c 100644 (file)
@@ -1,5 +1,10 @@
 2010-03-26  Richard Henderson  <rth@redhat.com>
 
+       * sysdeps/unix/alpha/sysdep.h (INTERNAL_SYSCALL_ERROR_P,
+       INTERNAL_SYSCALL_ERRNO): "Use" the "other" variable in each macro.
+
+2010-03-26  Richard Henderson  <rth@redhat.com>
+
        * sysdep/unix/sysv/linux/alpha/creat.c: New.
 
 2010-03-26  Richard Henderson  <rth@redhat.com>
index 2e5bc79..8accde0 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1995, 1996, 2000, 2003, 2004, 2006
+/* Copyright (C) 1992, 1995, 1996, 2000, 2003, 2004, 2006, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Brendan Kehoe (brendan@zen.org).
@@ -191,8 +191,10 @@ __LABEL(name)                                              \
 })
 
 #define INTERNAL_SYSCALL_DECL(err)             long int err
-#define INTERNAL_SYSCALL_ERROR_P(val, err)     err
-#define INTERNAL_SYSCALL_ERRNO(val, err)       val
+/* Make sure and "use" the variable that we're not returning,
+   in order to suppress unused variable warnings.  */
+#define INTERNAL_SYSCALL_ERROR_P(val, err)     ((void)val, err)
+#define INTERNAL_SYSCALL_ERRNO(val, err)       ((void)err, val)
 
 #define inline_syscall_clobbers                                \
        "$1", "$2", "$3", "$4", "$5", "$6", "$7", "$8", \