diff options
author | Ian Romanick <[email protected]> | 2014-03-04 15:39:37 +0200 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2014-05-02 11:58:36 -0700 |
commit | 59ad2e6696c51dc9b3514770abb550df663ecc7b (patch) | |
tree | 13337e5cea8865b2c544bec4e5f108c68ad07f8b /src/glsl/main.cpp | |
parent | 267e28bb62bb7ca2ebffc9a713bd5fa5fbd78ac7 (diff) |
mesa: Add _mesa_error_no_memory for logging out-of-memory messages
This can be called from locations that don't have a context pointer
handy. This patch also adds enough infrastructure so that the unit
tests for the GLSL compiler and the stand-alone compiler will build and
function.
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Juha-Pekka Heikkila <[email protected]>
Diffstat (limited to 'src/glsl/main.cpp')
-rw-r--r-- | src/glsl/main.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/glsl/main.cpp b/src/glsl/main.cpp index 4ae8f0987d5..a4452e023f2 100644 --- a/src/glsl/main.cpp +++ b/src/glsl/main.cpp @@ -40,6 +40,12 @@ static int glsl_version = 330; +extern "C" void +_mesa_error_no_memory(const char *caller) +{ + fprintf(stderr, "Mesa error: out of memory in %s", caller); +} + static void initialize_context(struct gl_context *ctx, gl_api api) { |