summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/context.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2019-05-09 21:04:23 -0400
committerMarek Olšák <[email protected]>2019-05-29 21:13:35 -0400
commitb5697c311b6f29dee40b96c48bad3279e3667c1e (patch)
treed0708cd5249ec8d3535bda8134f91ea79af2ffde /src/mesa/main/context.c
parent0f1b68ebeeee196ced42d8ac66d231338b507bad (diff)
Change a few frequented uses of DEBUG to !NDEBUG
debugoptimized builds don't define NDEBUG, but they also don't define DEBUG. We want to enable cheap debug code for these builds. I only chose those occurences that I care about. Reviewed-by: Mathias Fröhlich <[email protected]>
Diffstat (limited to 'src/mesa/main/context.c')
-rw-r--r--src/mesa/main/context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 34da16b88f4..03d81f1d559 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -939,7 +939,7 @@ nop_handler(const char *name)
if (ctx) {
_mesa_error(ctx, GL_INVALID_OPERATION, "%s(invalid call)", name);
}
-#if defined(DEBUG)
+#ifndef NDEBUG
else if (getenv("MESA_DEBUG") || getenv("LIBGL_DEBUG")) {
fprintf(stderr,
"GL User Error: gl%s called without a rendering context\n",