Commit 0d2943b3 authored by Philip Withnall's avatar Philip Withnall Committed by Olivier Crête

stun: Add printf function attribute

This shuts a compiler warning up and allows for format string checking
of debug messages.
parent b80a67d5
......@@ -37,6 +37,8 @@
#ifndef STUN_DEBUG_H
#define STUN_DEBUG_H
#include <stddef.h>
#ifdef __cplusplus
extern "C" {
#endif
......@@ -57,7 +59,12 @@ void stun_debug_enable (void);
void stun_debug_disable (void);
#if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4))
void stun_debug (const char *fmt, ...)
__attribute__((__format__ (__printf__, 1, 2)));
#else
void stun_debug (const char *fmt, ...);
#endif
void stun_debug_bytes (const void *data, size_t len);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment