summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
authorMartin Pool <mbp@samba.org>2002-01-09 05:27:59 +0000
committerMartin Pool <mbp@samba.org>2002-01-09 05:27:59 +0000
commitbb21af13e36d476e52a6151be1d7bbf9ed6e6412 (patch)
tree5fcf74ba66e952c550d0a4e2405bea08c8dfdfea /source3/include
parente4bf9af03cf0b7ff589f3ed67838aa210903cc86 (diff)
downloadsamba-bb21af13e36d476e52a6151be1d7bbf9ed6e6412.tar.gz
samba-bb21af13e36d476e52a6151be1d7bbf9ed6e6412.tar.bz2
samba-bb21af13e36d476e52a6151be1d7bbf9ed6e6412.zip
Add UNUSED(paramname) macro to be used in parameter lists, to quieten
gcc warnings about unused parameters. (This used to be commit b29775d442c36f667a6db5ba9dbe47d1a133525f)
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/includes.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/source3/include/includes.h b/source3/include/includes.h
index 6021ebb83b..fa6fad4605 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -2,9 +2,9 @@
#define _INCLUDES_H
/*
Unix SMB/Netbios implementation.
- Version 1.9.
Machine customisation and include handling
Copyright (C) Andrew Tridgell 1994-1998
+ Copyright (C) 2002 by Martin Pool <mbp@samba.org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -63,6 +63,15 @@
#define PRINTF_ATTRIBUTE(a1, a2)
#endif
+#ifdef __GNUC__
+/** gcc attribute used on function parameters so that it does not emit
+ * warnings about them being unused. **/
+# define UNUSED(param) param __attribute__ ((unused))
+#else
+# define UNUSED(param) param
+/** Feel free to add definitions for other compilers here. */
+#endif
+
#ifdef RELIANTUNIX
/*
* <unistd.h> has to be included before any other to get