egl: change default logging level to _EGL_WARNING

This commit is contained in:
Brian Paul 2008-06-06 15:10:22 -06:00
parent f0fdf0c23a
commit f6e030f531
1 changed files with 16 additions and 14 deletions

View File

@ -1,5 +1,7 @@
/**
* Logging facility for debug/info messages.
* _EGL_FATAL messages are printed to stderr
* The EGL_LOG_LEVEL var controls the output of other warning/info/debug msgs.
*/
@ -10,8 +12,8 @@
#include "egllog.h"
#define MAXSTRING 1000
#define FALLBACK_LOG_LEVEL _EGL_DEBUG
#define FALLBACK_LOG_LEVEL_STR "debug"
#define FALLBACK_LOG_LEVEL _EGL_WARNING
#define FALLBACK_LOG_LEVEL_STR "warning"
static EGLint ReportingLevel = -1;
@ -85,7 +87,7 @@ _eglLog(EGLint level, const char *fmtStr, ...)
vsnprintf(msg, MAXSTRING, fmtStr, args);
va_end(args);
fprintf(stderr, "EGL %s: %s\n", levelStr, msg);
fprintf(stderr, "libEGL %s: %s\n", levelStr, msg);
if (level == _EGL_FATAL) {
exit(1); /* or abort()? */