diff options
author | Mike Dransfield <mike@blueroot.co.uk> | 2007-05-31 20:52:50 +0100 |
---|---|---|
committer | Mike Dransfield <mike@blueroot.co.uk> | 2007-05-31 20:54:26 +0100 |
commit | 0a1e76975d0dd55cb788db2c90a088c1125cb2a0 (patch) | |
tree | 5a23352e5f2fe570e97921856a0e03fc460b22b1 /src/fragment.c | |
parent | de76d335a4083cf9fce37465e264b5d458c38133 (diff) |
Add extensible logging framework
Diffstat (limited to 'src/fragment.c')
-rw-r--r-- | src/fragment.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/fragment.c b/src/fragment.c index 18bd9df1..1c358586 100644 --- a/src/fragment.c +++ b/src/fragment.c @@ -587,9 +587,9 @@ buildFragmentProgram (CompScreen *s, if (!mask) { - fprintf (stderr, "%s: fragment functions can't be linked together " - "because a common type doesn't exist\n", - programName); + compLogMessage (NULL, "core", CompLogLevelWarn, + "fragment functions can't be linked together " + "because a common type doesn't exist"); } if (!mask || nFunctionList == 1) @@ -639,7 +639,8 @@ buildFragmentProgram (CompScreen *s, glGetIntegerv (GL_PROGRAM_ERROR_POSITION_ARB, &errorPos); if (glGetError () != GL_NO_ERROR || errorPos != -1) { - fprintf (stderr, "%s: failed to load fragment program\n", programName); + compLogMessage (NULL, "core", CompLogLevelError, + "failed to load fragment program"); (*s->deletePrograms) (1, &program->name); @@ -932,7 +933,8 @@ addHeaderOpToFunctionData (CompFunctionData *data, { if (strncmp (name, reserved[i], strlen (reserved[i])) == 0) { - fprintf (stderr, "%s: %s is a reserved word\n", programName, name); + compLogMessage (NULL, "core", CompLogLevelWarn, + "%s is a reserved word", name); return FALSE; } } |