mirror of
https://github.com/markqvist/Reticulum.git
synced 2025-08-10 07:21:01 -04:00
Fix exit method to use sys.exit for proper cleanup
Change RNS.__init__.py exit method from os._exit to sys.exit to allow proper cleanup and exception handling. Keep panic method using os._exit for immediate termination in unrecoverable scenarios.
This commit is contained in:
parent
799bcfc7aa
commit
1db7ff42c5
1 changed files with 2 additions and 2 deletions
|
@ -382,7 +382,7 @@ def exit(code=0):
|
|||
if not exit_called:
|
||||
exit_called = True
|
||||
Reticulum.exit_handler()
|
||||
os._exit(code)
|
||||
sys.exit(code)
|
||||
|
||||
class Profiler:
|
||||
_ran = False
|
||||
|
@ -541,4 +541,4 @@ class Profiler:
|
|||
if tag["super"] == None:
|
||||
print_results_recursive(tag, results)
|
||||
|
||||
profile = Profiler.get_profiler
|
||||
profile = Profiler.get_profiler
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue