radv/winsys: check more allocation failures
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Sun, 12 Jul 2020 14:00:35 +0000 (16:00 +0200)
committerMarge Bot <eric+marge@anholt.net>
Wed, 22 Jul 2020 15:06:20 +0000 (15:06 +0000)
commitf0112fa13cc68d3a20ddfec71540cb863b315f23
treee2142ba62ee5bb5c2c018fddedb109b06f109b38
parent7a61e31d7b2e9a486686740fad11d58745fa9cc9
radv/winsys: check more allocation failures

While we are at it, use local variables first to make sure to
not leak memory if something bad happens.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5872>
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_bo.c
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_cs.c