Add a macro for marking a variable or function argument as unused.

git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@656 185d5e19-27fe-0310-9dcf-9bff6b9f3609
This commit is contained in:
Dag-Erling Smørgrav 2013-03-06 22:58:45 +00:00
parent 7bcd5bb700
commit efe65a2cab
1 changed files with 9 additions and 3 deletions

View File

@ -2,8 +2,8 @@
* $Id$
*/
#ifndef SECURITY_PAM_ATTRIBUTES_H_INCLUDED
#define SECURITY_PAM_ATTRIBUTES_H_INCLUDED
#ifndef SECURITY_OPENPAM_ATTR_H_INCLUDED
#define SECURITY_OPENPAM_ATTR_H_INCLUDED
/* GCC attributes */
#if defined(__GNUC__) && defined(__GNUC_MINOR__) && !defined(__STRICT_ANSI__)
@ -25,4 +25,10 @@
# define OPENPAM_NONNULL(params)
#endif
#endif /* !SECURITY_PAM_ATTRIBUTES_H_INCLUDED */
#if OPENPAM_GNUC_PREREQ(2,7)
# define OPENPAM_UNUSED(var) var __attribute__((__unused__))
#else
# define OPENPAM_UNUSED(var) var
#endif
#endif /* !SECURITY_OPENPAM_ATTR_H_INCLUDED */