* some log-message at application start. This is a handy-helper to do this.
*/
+__attribute__((format(printf, 7, 0)))
void log_submit(const char *file,
int line,
const char *func,
const char *format,
va_list args);
+__attribute__((format(printf, 7, 8)))
void log_format(const char *file,
int line,
const char *func,
const char *format,
...);
+__attribute__((format(printf, 6, 0)))
void log_llog(const char *file,
int line,
const char *func,
int log_set_file(const char *file);
void log_print_init(const char *appname);
-static inline void log_dummyf(unsigned int sev, const char *format, ...)
+static inline __attribute__((format(printf, 2, 3)))
+void log_dummyf(unsigned int sev, const char *format, ...)
{
}
const char *format,
va_list args);
-__attribute__((__unused__))
-static void llog_format(llog_submit_t llog,
- const char *file,
- int line,
- const char *func,
- const char *subs,
- unsigned int sev,
- const char *format,
- ...)
+static inline __attribute__((format(printf, 7, 8)))
+void llog_format(llog_submit_t llog,
+ const char *file,
+ int line,
+ const char *func,
+ const char *subs,
+ unsigned int sev,
+ const char *format,
+ ...)
{
va_list list;
#define llog_dprintf(obj, sev, format, ...) \
llog_format((obj), LLOG_DEFAULT, (sev), (format), ##__VA_ARGS__)
-static inline void llog_dummyf(llog_submit_t llog, unsigned int sev,
- const char *format, ...)
+static inline __attribute__((format(printf, 3, 4)))
+void llog_dummyf(llog_submit_t llog, unsigned int sev,
+ const char *format, ...)
{
}