mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-23 07:06:30 +00:00
Prevent compiler warnings with 9.0
PG_PRINTF_ATTRIBUTE was introduced with 9.1.
This commit is contained in:
6
log.h
6
log.h
@@ -25,9 +25,15 @@
|
||||
#define REPMGR_SYSLOG 1
|
||||
#define REPMGR_STDERR 2
|
||||
|
||||
#if (PG_VERSION_NUM >= 90100)
|
||||
void
|
||||
stderr_log_with_level(const char *level_name, int level, const char *fmt,...)
|
||||
__attribute__((format(PG_PRINTF_ATTRIBUTE, 3, 4)));
|
||||
#else
|
||||
void
|
||||
stderr_log_with_level(const char *level_name, int level, const char *fmt,...)
|
||||
__attribute__((format(printf, 3, 4)));
|
||||
#endif
|
||||
|
||||
/* Standard error logging */
|
||||
#define stderr_log_debug(...) stderr_log_with_level("DEBUG", LOG_DEBUG, __VA_ARGS__)
|
||||
|
||||
Reference in New Issue
Block a user