git://git.onelab.eu
/
ipfw.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
01dfb3c
)
Undefine the __unused macro around problematic places.
author
marta
<marta@onelab7.(none)>
Fri, 21 Jan 2011 11:42:43 +0000
(12:42 +0100)
committer
marta
<marta@onelab7.(none)>
Fri, 21 Jan 2011 11:42:43 +0000
(12:42 +0100)
ipfw/ipfw2.c
patch
|
blob
|
history
diff --git
a/ipfw/ipfw2.c
b/ipfw/ipfw2.c
index
9e2dd59
..
6cb826b
100644
(file)
--- a/
ipfw/ipfw2.c
+++ b/
ipfw/ipfw2.c
@@
-40,7
+40,14
@@
#include <time.h> /* ctime */
#include <timeconv.h> /* _long_to_time */
#include <unistd.h>
#include <time.h> /* ctime */
#include <timeconv.h> /* _long_to_time */
#include <unistd.h>
+/*
+ * FreeBSD uses __unused as a shorthand for __attribute__ ((__unused__))
+ * whereas Linux sometimes uses __unused as a variable name.
+ * undefine the macro around problematic places.
+ */
+#undef __unused
#include <fcntl.h>
#include <fcntl.h>
+#define __unused __attribute__ ((__unused__))
#include <net/ethernet.h>
#include <net/if.h> /* only IFNAMSIZ */
#include <net/ethernet.h>
#include <net/if.h> /* only IFNAMSIZ */