diff options
| author | Jonathan Bradley <jcb@pikum.xyz> | 2025-01-30 16:05:59 -0500 |
|---|---|---|
| committer | Jonathan Bradley <jcb@pikum.xyz> | 2025-01-30 16:05:59 -0500 |
| commit | a13b4a8296a8623cb50a4ec5d23a1e39b3e019c0 (patch) | |
| tree | 204f3cb867f4a5645a50bdde5d5131b0d22550a7 /editor | |
| parent | 58258993a1bcd0ee877e2987ebfd7ebeff02b491 (diff) | |
editor: better teardown handling
Diffstat (limited to 'editor')
| -rw-r--r-- | editor/editor.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/editor/editor.cpp b/editor/editor.cpp index bc5d072..b3d0f4a 100644 --- a/editor/editor.cpp +++ b/editor/editor.cpp @@ -1521,7 +1521,8 @@ void PkeEditor_Setup() { void PkeEditor_Disable() { shouldDisableEditor = false; - PkeInput_DeactivateSet(debugControlsHandle); + if (debugControlsHandle != InputActionSetHandle_MAX) + PkeInput_DeactivateSet(debugControlsHandle); } void PkeEditor_Teardown() { @@ -1529,7 +1530,8 @@ void PkeEditor_Teardown() { if (subProgramPid != -1) { kill(subProgramPid, SIGINT); } - PkeThreads_Teardown(threadPoolHandle); + if (threadPoolHandle != ThreadPoolHandle_MAX) + PkeThreads_Teardown(threadPoolHandle); entityInstancesToCreate.~DynArray(); } |
