Cleanup: add printf function attributes, quiet GCC warnings
This commit is contained in:
@@ -212,6 +212,9 @@ static bool malloc_debug_memset = false;
|
||||
/* implementation */
|
||||
/* --------------------------------------------------------------------- */
|
||||
|
||||
#ifdef __GNUC__
|
||||
__attribute__((format(printf, 1, 0)))
|
||||
#endif
|
||||
static void print_error(const char *message, va_list str_format_args)
|
||||
{
|
||||
char buf[512];
|
||||
|
||||
@@ -74,6 +74,9 @@ enum {
|
||||
#define MEMHEAD_IS_FROM_CPP_NEW(memhead) ((memhead)->len & size_t(MEMHEAD_FLAG_FROM_CPP_NEW))
|
||||
#define MEMHEAD_LEN(memhead) ((memhead)->len & ~size_t(MEMHEAD_FLAG_MASK))
|
||||
|
||||
#ifdef __GNUC__
|
||||
__attribute__((format(printf, 1, 0)))
|
||||
#endif
|
||||
static void print_error(const char *message, va_list str_format_args)
|
||||
{
|
||||
char buf[512];
|
||||
|
||||
Reference in New Issue
Block a user