Discussion:
[PATCH app/fonttosfnt] Mark vsprintf_alloc as printf-like function
Peter Hutterer
2018-10-31 04:46:10 UTC
Permalink
Signed-off-by: Peter Hutterer <***@who-t.net>
---
Review this quickly please, we have another release coming up in 9 years
time and I don't want to miss the merge window.

util.c | 3 +++
1 file changed, 3 insertions(+)

diff --git a/util.c b/util.c
index 81c0489..5a23eeb 100644
--- a/util.c
+++ b/util.c
@@ -37,6 +37,7 @@ THE SOFTWARE.
#include FT_FREETYPE_H
#include FT_BDF_H
#include "X11/Xos.h"
+#include "X11/Xfuncproto.h" /* for _X_ATTRIBUTE_PRINTF */
#include "fonttosfnt.h"

#ifdef NEED_SNPRINTF
@@ -80,6 +81,7 @@ sprintf_alloc(const char *f, ...)
}

#if HAVE_VASPRINTF
+_X_ATTRIBUTE_PRINTF(1, 0)
char*
vsprintf_alloc(const char *f, va_list args)
{
@@ -92,6 +94,7 @@ vsprintf_alloc(const char *f, va_list args)
return r;
}
#else
+_X_ATTRIBUTE_PRINTF(1, 0)
char*
vsprintf_alloc(const char *f, va_list args)
{
--
2.19.1

_______________________________________________
xorg-***@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.or
Eric Anholt
2018-11-01 19:49:04 UTC
Permalink
Post by Peter Hutterer
---
Review this quickly please, we have another release coming up in 9 years
time and I don't want to miss the merge window.
Reviewed-by: Eric Anholt <***@anholt.net>

Loading...