Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix double free in QuickOpenDialog deconstructor #97746

Merged
merged 1 commit into from
Oct 2, 2024

Conversation

stijn-h
Copy link
Contributor

@stijn-h stijn-h commented Oct 2, 2024

Before opening the dialog, the result nodes are created but not assigned to either the list or grid container. In this case we must free them manually (well I wouldn't care but the sanitizer complains). But if you open the dialog once, the results will be parented to one container, and therefore automatically freed. The double free resulted in a segfault.

I considered adding the results to one container at startup, but the current method also fetches theme icons so i can't do it in the constructor so this is the simplest way out.

Should fix #97733

@stijn-h stijn-h requested review from a team as code owners October 2, 2024 17:50
@KoBeWi KoBeWi added this to the 4.4 milestone Oct 2, 2024
@akien-mga akien-mga merged commit cf34d32 into godotengine:master Oct 2, 2024
19 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Editor crash when closing the app caused by the new quick open dialog
3 participants