Merge pull request #74496 from juliuse98/master

Fix blend-file import when using custom color management in blender
This commit is contained in:
Rémi Verschelde 2023-03-07 08:39:43 +01:00
commit 13ad374102
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -297,13 +297,14 @@ static bool _test_blender_path(const String &p_path, String *r_err = nullptr) {
}
return false;
}
if (pipe.find("Blender ") != 0) {
int bl = pipe.find("Blender ");
if (bl == -1) {
if (r_err) {
*r_err = vformat(TTR("Unexpected --version output from Blender binary at: %s"), path);
}
return false;
}
pipe = pipe.substr(bl);
pipe = pipe.replace_first("Blender ", "");
int pp = pipe.find(".");
if (pp == -1) {