aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/include
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@apple.com>2016-06-29 12:38:31 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2016-07-05 08:11:41 +0200
commitb91099b977ea7b3757adfebb3fad930ee0411c4f (patch)
tree038a2e5fdc924ebc941c228573d97246c3547da6 /nx-X11/include
parentcef6d723cb003a6f9b2cf1cb37eb340dad6a76e6 (diff)
downloadnx-libs-b91099b977ea7b3757adfebb3fad930ee0411c4f.tar.gz
nx-libs-b91099b977ea7b3757adfebb3fad930ee0411c4f.tar.bz2
nx-libs-b91099b977ea7b3757adfebb3fad930ee0411c4f.zip
Add _X_UNUSED attribute to designate unused variables and silence warnings
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com> Reviewed-by: Daniel Stone <daniel@fooishbar.org> Backport to nx-libs: Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
Diffstat (limited to 'nx-X11/include')
-rw-r--r--nx-X11/include/Xfuncproto.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/nx-X11/include/Xfuncproto.h b/nx-X11/include/Xfuncproto.h
index a18ac19c4..f6729a0d9 100644
--- a/nx-X11/include/Xfuncproto.h
+++ b/nx-X11/include/Xfuncproto.h
@@ -97,4 +97,11 @@ in this Software without prior written authorization from The Open Group.
# define _X_DEPRECATED
#endif
+/* requires xproto >= 7.0.22 */
+#if defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 205)
+#define _X_UNUSED __attribute__((__unused__))
+#else
+#define _X_UNUSED /* */
+#endif
+
#endif /* _XFUNCPROTO_H_ */