From cd61f5234d2c275b21c249fc2effc058a74ecf0a Mon Sep 17 00:00:00 2001 From: Bas Nieuwenhuizen Date: Sat, 23 May 2020 02:26:04 +0200 Subject: [PATCH] radv: Handle failing to create .cache dir. Fixes: f4e499ec791 "radv: add initial non-conformant radv vulkan driver" Reviewed-by: Samuel Pitoiset Part-of: --- src/amd/vulkan/radv_meta.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_meta.c b/src/amd/vulkan/radv_meta.c index 0acffbc5ccd..6d2f24d148f 100644 --- a/src/amd/vulkan/radv_meta.c +++ b/src/amd/vulkan/radv_meta.c @@ -262,7 +262,8 @@ radv_builtin_cache_path(char *path) strcpy(path, pwd.pw_dir); strcat(path, "/.cache"); - mkdir(path, 0755); + if (mkdir(path, 0755)) + return false; ret = snprintf(path, PATH_MAX + 1, "%s%s%zd", pwd.pw_dir, suffix2, sizeof(void *) * 8); -- 2.30.2