diff options
author | Chad Versace <chad.versace@intel.com> | 2015-05-05 19:05:30 -0700 |
---|---|---|
committer | Chad Versace <chad.versace@intel.com> | 2015-05-07 08:11:21 -0700 |
commit | 00f3c7baeb3e8f00ce7bc8a1384ef545e648f1d9 (patch) | |
tree | 4d4256f30241ed926cbd4e7fe20c7663a2527123 | |
parent | 9cf9a2dec5b3fe3aad878b8ab99d50fbd51e1b9c (diff) | |
download | external_mesa3d-00f3c7baeb3e8f00ce7bc8a1384ef545e648f1d9.zip external_mesa3d-00f3c7baeb3e8f00ce7bc8a1384ef545e648f1d9.tar.gz external_mesa3d-00f3c7baeb3e8f00ce7bc8a1384ef545e648f1d9.tar.bz2 |
i965/sync: Return NULL when calloc fails
Reviewed-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_syncobj.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_syncobj.c b/src/mesa/drivers/dri/i965/intel_syncobj.c index 3bc32df..a425b9e 100644 --- a/src/mesa/drivers/dri/i965/intel_syncobj.c +++ b/src/mesa/drivers/dri/i965/intel_syncobj.c @@ -50,6 +50,8 @@ intel_new_sync_object(struct gl_context *ctx, GLuint id) struct intel_sync_object *sync; sync = calloc(1, sizeof(struct intel_sync_object)); + if (!sync) + return NULL; return &sync->Base; } |