diff options
author | Guillaume Nault <g.nault@alphalink.fr> | 2012-09-04 20:29:08 +0200 |
---|---|---|
committer | Kozlov Dmitry <xeb@mail.ru> | 2012-09-05 22:31:15 +0400 |
commit | fdeeb6f8547617a0478ffe847b76c46fa45487d0 (patch) | |
tree | c752b9596ea007c71ece84f38af6db08d5dd7478 /accel-pppd/triton/triton_p.h | |
parent | 36cc9c11a194be371dad562df8b2eff548586749 (diff) | |
download | accel-ppp-fdeeb6f8547617a0478ffe847b76c46fa45487d0.tar.gz accel-ppp-fdeeb6f8547617a0478ffe847b76c46fa45487d0.zip |
Add compilation checks for printf-style format strings
Append the format() __attribute__ to function prototypes which
use a format string. This allows GCC to check for consistency
between the format string and its arguments when these
functions are called.
Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Diffstat (limited to 'accel-pppd/triton/triton_p.h')
-rw-r--r-- | accel-pppd/triton/triton_p.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/accel-pppd/triton/triton_p.h b/accel-pppd/triton/triton_p.h index 2eb2e62a..443cedea 100644 --- a/accel-pppd/triton/triton_p.h +++ b/accel-pppd/triton/triton_p.h @@ -104,8 +104,8 @@ int triton_queue_ctx(struct _triton_context_t*); void triton_thread_wakeup(struct _triton_thread_t*); int conf_load(const char *fname); int conf_reload(const char *fname); -void triton_log_error(const char *fmt,...); -void triton_log_debug(const char *fmt,...); +void triton_log_error(const char *fmt, ...) __attribute__((format(gnu_printf, 1, 2))); +void triton_log_debug(const char *fmt, ...) __attribute__((format(gnu_printf, 1, 2))); int load_modules(const char *name); #endif |