diff options
Diffstat (limited to 'src/mesa/main/imports.c')
-rw-r--r-- | src/mesa/main/imports.c | 67 |
1 files changed, 3 insertions, 64 deletions
diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c index 10224f78882..112490915f7 100644 --- a/src/mesa/main/imports.c +++ b/src/mesa/main/imports.c @@ -828,67 +828,6 @@ _mesa_str_checksum(const char *str) /**********************************************************************/ -/** \name I/O */ -/*@{*/ - -/** Wrapper around vsprintf() */ -int -_mesa_sprintf( char *str, const char *fmt, ... ) -{ - int r; - va_list args; - va_start( args, fmt ); - r = vsprintf( str, fmt, args ); - va_end( args ); - 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, ... ) -{ - va_list args; - va_start( args, fmtString ); - vfprintf(stderr, fmtString, args); - va_end( args ); -} - -/** Wrapper around fprintf(), using vsprintf() for the formatting. */ -void -_mesa_fprintf( FILE *f, const char *fmtString, ... ) -{ - char s[MAXSTRING]; - va_list args; - va_start( args, fmtString ); - vsnprintf(s, MAXSTRING, fmtString, args); - va_end( args ); - fprintf(f, "%s", s); -} - - -/** Wrapper around vsprintf() */ -int -_mesa_vsprintf( char *str, const char *fmt, va_list args ) -{ - return vsprintf( str, fmt, args ); -} - -/*@}*/ - - -/**********************************************************************/ /** \name Diagnostics */ /*@{*/ @@ -927,7 +866,7 @@ output_if_debug(const char *prefixString, const char *outputString, * visible, so communicate with the debugger instead */ { char buf[4096]; - _mesa_snprintf(buf, sizeof(buf), "%s: %s%s", prefixString, outputString, newline ? "\n" : ""); + snprintf(buf, sizeof(buf), "%s: %s%s", prefixString, outputString, newline ? "\n" : ""); OutputDebugStringA(buf); } #endif @@ -976,7 +915,7 @@ flush_delayed_errors( GLcontext *ctx ) char s[MAXSTRING]; if (ctx->ErrorDebugCount) { - _mesa_snprintf(s, MAXSTRING, "%d similar %s errors", + snprintf(s, MAXSTRING, "%d similar %s errors", ctx->ErrorDebugCount, error_string(ctx->ErrorValue)); @@ -1083,7 +1022,7 @@ _mesa_error( GLcontext *ctx, GLenum error, const char *fmtString, ... ) vsnprintf(s, MAXSTRING, fmtString, args); va_end(args); - _mesa_snprintf(s2, MAXSTRING, "%s in %s", error_string(error), s); + snprintf(s2, MAXSTRING, "%s in %s", error_string(error), s); output_if_debug("Mesa: User error", s2, GL_TRUE); ctx->ErrorDebugFmtString = fmtString; |