Skip to content

Fix crash on picking game media folder on Windows due to null directory#387

Merged
rsubtil merged 1 commit intomainfrom
fix_windows_crash_with_null_dir
Jan 19, 2025
Merged

Fix crash on picking game media folder on Windows due to null directory#387
rsubtil merged 1 commit intomainfrom
fix_windows_crash_with_null_dir

Conversation

@rsubtil
Copy link
Member

@rsubtil rsubtil commented Jan 18, 2025

It appears that opening an invalid directory on Windows returns a null instance, unlike on Linux. Because this is not tested explicitly, it then crashes due to dereferencing it. This check prevents this on Windows.

@rsubtil
Copy link
Member Author

rsubtil commented Jan 19, 2025

From testing in the Discord, it seems this fixed the issue.

@rsubtil rsubtil merged commit 7a6dcda into main Jan 19, 2025
15 of 21 checks passed
@rsubtil rsubtil deleted the fix_windows_crash_with_null_dir branch January 19, 2025 18:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant