mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 11:48:06 +02:00
radv: Only close local_fd when valid
Necessary when drm_device is bypassed. Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7119>
This commit is contained in:
parent
4ca6faa933
commit
7758664788
1 changed files with 2 additions and 1 deletions
|
|
@ -466,7 +466,8 @@ radv_physical_device_destroy(struct radv_physical_device *device)
|
|||
radv_finish_wsi(device);
|
||||
device->ws->destroy(device->ws);
|
||||
disk_cache_destroy(device->disk_cache);
|
||||
close(device->local_fd);
|
||||
if (device->local_fd != -1)
|
||||
close(device->local_fd);
|
||||
if (device->master_fd != -1)
|
||||
close(device->master_fd);
|
||||
vk_free(&device->instance->alloc, device);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue