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 <Mathias.Froehlich@web.de>
This commit is contained in:
Marek Olšák
2019-05-09 21:04:23 -04:00
parent 0f1b68ebee
commit b5697c311b
18 changed files with 27 additions and 29 deletions

View File

@@ -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",