From 51729b5119df450f2f80c4e648b99fa35b9ec32d Mon Sep 17 00:00:00 2001 From: Alan Hourihane Date: Wed, 16 Jun 2010 17:55:00 +0100 Subject: [PATCH] draw: add alloc check --- src/gallium/auxiliary/draw/draw_llvm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/auxiliary/draw/draw_llvm.c b/src/gallium/auxiliary/draw/draw_llvm.c index bd5d8853cf8..9117c1303dc 100644 --- a/src/gallium/auxiliary/draw/draw_llvm.c +++ b/src/gallium/auxiliary/draw/draw_llvm.c @@ -173,6 +173,8 @@ draw_llvm_create(struct draw_context *draw) #endif llvm = CALLOC_STRUCT( draw_llvm ); + if (!llvm) + return NULL; llvm->draw = draw; llvm->engine = draw->engine; -- 2.30.2