]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Fix compile on Linux where.
authorRoy Marples <roy@marples.name>
Mon, 21 Jan 2008 21:52:20 +0000 (21:52 +0000)
committerRoy Marples <roy@marples.name>
Mon, 21 Jan 2008 21:52:20 +0000 (21:52 +0000)
common.h
interface.c

index 3dbae4b8f32bdfab4b3e83d4b3143f54acc54b34..61732bb62ac912f1154244dca7086740ffabe2c4 100644 (file)
--- a/common.h
+++ b/common.h
 #include <stdio.h>
 #include <string.h>
 
+#if __GNUC__ > 2 || defined(__INTEL_COMPILER)
+# define _unused __attribute__((__unused__))
+#endif
+
 #define HAVE_STRLCPY
 /* Only GLIBC doesn't support strlcpy */
 #ifdef __GLIBC__
index e39f7fa430be5e59f6f497b7a77b6d0887f27739..158855fe14166dc2cd4175479cd133d736ee62b5 100644 (file)
@@ -454,7 +454,7 @@ int set_mtu (const char *ifname, short int mtu)
 static void log_route (struct in_addr destination,
                       struct in_addr netmask,
                       struct in_addr gateway,
-                      __unused int metric,
+                      _unused int metric,
                       int change, int del)
 {
        char *dstd = xstrdup (inet_ntoa (destination));