Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
7dac5bd2
Unverified
Commit
7dac5bd2
authored
Jun 24, 2020
by
Rémi Verschelde
Committed by
GitHub
Jun 24, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #39798 from akien-mga/main-keep-messagequeue-to-deinit-scene
Main::cleanup: Move MessageQueue deletion further down where it's safer
parents
850134af
6480efba
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
main.cpp
main/main.cpp
+5
-1
No files found.
main/main.cpp
View file @
7dac5bd2
...
@@ -2321,8 +2321,8 @@ void Main::cleanup() {
...
@@ -2321,8 +2321,8 @@ void Main::cleanup() {
ResourceLoader
::
remove_custom_loaders
();
ResourceLoader
::
remove_custom_loaders
();
ResourceSaver
::
remove_custom_savers
();
ResourceSaver
::
remove_custom_savers
();
// Flush before uninitializing the scene, but delete the MessageQueue as late as possible.
message_queue
->
flush
();
message_queue
->
flush
();
memdelete
(
message_queue
);
OS
::
get_singleton
()
->
delete_main_loop
();
OS
::
get_singleton
()
->
delete_main_loop
();
...
@@ -2408,6 +2408,10 @@ void Main::cleanup() {
...
@@ -2408,6 +2408,10 @@ void Main::cleanup() {
OS
::
get_singleton
()
->
set_restart_on_exit
(
false
,
List
<
String
>
());
//clear list (uses memory)
OS
::
get_singleton
()
->
set_restart_on_exit
(
false
,
List
<
String
>
());
//clear list (uses memory)
}
}
// Now should be safe to delete MessageQueue (famous last words).
message_queue
->
flush
();
memdelete
(
message_queue
);
unregister_core_driver_types
();
unregister_core_driver_types
();
unregister_core_types
();
unregister_core_types
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment