clc: remove check for null pointer that cannot be true in llvm_mod_to_spirv

Snce the *args parameter was added it's assumed to be non-null. If it is
null then the function is going off to UB land. As such, a later check
added for args being NULL is useless, and confuses coverity.

fixes: 3a752256f5

Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29664>
This commit is contained in:
Dylan Baker 2024-06-10 13:45:50 -07:00 committed by Marge Bot
parent 9fa310b876
commit e67a8dc59a

View file

@ -1039,9 +1039,7 @@ llvm_mod_to_spirv(std::unique_ptr<::llvm::Module> mod,
return -1;
}
const char *const *extensions = NULL;
if (args)
extensions = args->allowed_spirv_extensions;
const char *const *extensions = args->allowed_spirv_extensions;
if (!extensions) {
/* The SPIR-V parser doesn't handle all extensions */
static const char *default_extensions[] = {