summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/imports.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/imports.c')
-rw-r--r--src/mesa/main/imports.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c
index 6cfd7ccc723..69d55923c37 100644
--- a/src/mesa/main/imports.c
+++ b/src/mesa/main/imports.c
@@ -930,6 +930,18 @@ _mesa_sprintf( char *str, const char *fmt, ... )
return r;
}
+/** Wrapper around vsnprintf() */
+int
+_mesa_snprintf( char *str, size_t size, const char *fmt, ... )
+{
+ int r;
+ va_list args;
+ va_start( args, fmt );
+ r = vsnprintf( str, size, fmt, args );
+ va_end( args );
+ return r;
+}
+
/** Wrapper around printf(), using vsprintf() for the formatting. */
void
_mesa_printf( const char *fmtString, ... )