summaryrefslogtreecommitdiff
path: root/libavutil
diff options
context:
space:
mode:
Diffstat (limited to 'libavutil')
-rw-r--r--libavutil/avstring.h3
-rw-r--r--libavutil/log.h7
2 files changed, 4 insertions, 6 deletions
diff --git a/libavutil/avstring.h b/libavutil/avstring.h
index b40acf6ebb..44ed89d654 100644
--- a/libavutil/avstring.h
+++ b/libavutil/avstring.h
@@ -22,6 +22,7 @@
#define AVUTIL_AVSTRING_H
#include <stddef.h>
+#include "attributes.h"
/**
* Return non-zero if pfx is a prefix of str. If it is, *ptr is set to
@@ -107,7 +108,7 @@ size_t av_strlcat(char *dst, const char *src, size_t size);
* @return the length of the string that would have been generated
* if enough space had been available
*/
-size_t av_strlcatf(char *dst, size_t size, const char *fmt, ...);
+size_t av_strlcatf(char *dst, size_t size, const char *fmt, ...) av_printf_format(3, 4);
/**
* Convert a number to a av_malloced string.
diff --git a/libavutil/log.h b/libavutil/log.h
index c823a763ee..c1d9a6c393 100644
--- a/libavutil/log.h
+++ b/libavutil/log.h
@@ -23,6 +23,7 @@
#include <stdarg.h>
#include "avutil.h"
+#include "attributes.h"
/**
* Describe the class of an AVClass context structure. That is an
@@ -129,11 +130,7 @@ typedef struct {
* subsequent arguments are converted to output.
* @see av_vlog
*/
-#ifdef __GNUC__
-void av_log(void *avcl, int level, const char *fmt, ...) __attribute__ ((__format__ (__printf__, 3, 4)));
-#else
-void av_log(void *avcl, int level, const char *fmt, ...);
-#endif
+void av_log(void *avcl, int level, const char *fmt, ...) av_printf_format(3, 4);
void av_vlog(void *avcl, int level, const char *fmt, va_list);
int av_log_get_level(void);