i965: fix missing NULL return if allocation fails

CID: 1250585
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
This commit is contained in:
Lionel Landwerlin
2017-07-13 16:29:25 +01:00
parent 95c917668c
commit 7c4daf8c37

View File

@@ -99,6 +99,7 @@ brw_new_buffer_object(struct gl_context * ctx, GLuint name)
struct intel_buffer_object *obj = CALLOC_STRUCT(intel_buffer_object);
if (!obj) {
_mesa_error_no_memory(__func__);
return NULL;
}
_mesa_initialize_buffer_object(ctx, &obj->Base, name);