1 /*
2  * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
3  *
4  * This Source Code Form is subject to the terms of the Mozilla Public
5  * License, v. 2.0. If a copy of the MPL was not distributed with this
6  * file, you can obtain one at https://mozilla.org/MPL/2.0/.
7  *
8  * See the COPYRIGHT file distributed with this work for additional
9  * information regarding copyright ownership.
10  */
11 
12 #ifndef ISC_FORMATCHECK_H
13 #define ISC_FORMATCHECK_H 1
14 
15 /*! \file isc/formatcheck.h */
16 
17 /*%
18  * ISC_FORMAT_PRINTF().
19  *
20  * \li fmt is the location of the format string parameter.
21  * \li args is the location of the first argument (or 0 for no argument
22  * checking).
23  *
24  * Note:
25  * \li The first parameter is 1, not 0.
26  */
27 #ifdef __GNUC__
28 #define ISC_FORMAT_PRINTF(fmt, args) \
29 	__attribute__((__format__(__printf__, fmt, args)))
30 #else /* ifdef __GNUC__ */
31 #define ISC_FORMAT_PRINTF(fmt, args)
32 #endif /* ifdef __GNUC__ */
33 
34 #endif /* ISC_FORMATCHECK_H */
35