meta: Avoid random memory access on error
authorJuha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Sat, 16 Apr 2016 19:26:22 +0000 (22:26 +0300)
committerChad Versace <chad.versace@intel.com>
Tue, 26 Apr 2016 21:54:02 +0000 (14:54 -0700)
commit51632d6f27860c4e217a34fbb23864dfa56c4c48
tree8026d0b355e0df1522dd503148f7e688f65ecaab
parentcea3a7e6153b69b34bb8a8484b27463ad123bcc2
meta: Avoid random memory access on error

Initialize drawFb to NULL in _mesa_meta_CopyImageSubData_uncompressed()
if getting readFb fails uninitialized drawFb will cause randomness
on cleanup.

Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Reviewed-by: Eduardo Lima Mitev <elima@igalia.com>
Reviewed-by: Chad Versace <chad.versace@intel.com>
src/mesa/drivers/common/meta_copy_image.c