vkd3d-compiler: Set a default target type even when preprocessing.

We largely ignore the target type when preprocessing, but still
dereference options.target_type in a couple of places. E.g. when setting
info.target_type. We could add more checks for options.preprocess_only
to account for that, but it seems more robust to make sure
options.target_type is never NULL.
This commit is contained in:
Francisco Casas
2025-08-12 10:56:26 -04:00
committed by Henri Verbeet
parent cab0bd07e5
commit 7007a1e264
Notes: Henri Verbeet 2025-08-13 16:28:11 +02:00
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1680

View File

@@ -891,7 +891,7 @@ int main(int argc, char **argv)
}
}
if (!options.target_type && !options.preprocess_only)
if (!options.target_type)
options.target_type = get_target_type_info(options.source_type->default_target_type);
if (!options.preprocess_only && !validate_target_type(options.source_type->type, options.target_type->type))