Mercurial > octave
comparison libinterp/corefcn/interpreter.cc @ 31040:0ee18536ec5c
maint: Merge stable to default.
author | Markus Mützel <markus.muetzel@gmx.de> |
---|---|
date | Sat, 28 May 2022 13:37:49 +0200 |
parents | 32d2b6604a9f ecb867dfc8eb |
children | 670a0d878af1 |
comparison
equal
deleted
inserted
replaced
31038:39ca6d0b63e4 | 31040:0ee18536ec5c |
---|---|
657 | 657 |
658 OCTAVE_THREAD_LOCAL interpreter *interpreter::m_instance = nullptr; | 658 OCTAVE_THREAD_LOCAL interpreter *interpreter::m_instance = nullptr; |
659 | 659 |
660 interpreter::~interpreter (void) | 660 interpreter::~interpreter (void) |
661 { | 661 { |
662 if (! m_app_context) | |
663 shutdown (); | |
664 | |
662 delete m_gh_manager; | 665 delete m_gh_manager; |
663 } | 666 } |
664 | 667 |
665 void interpreter::intern_nargin (octave_idx_type nargs) | 668 void interpreter::intern_nargin (octave_idx_type nargs) |
666 { | 669 { |
909 exit_status = server_loop (); | 912 exit_status = server_loop (); |
910 } | 913 } |
911 } | 914 } |
912 else | 915 else |
913 exit_status = main_loop (); | 916 exit_status = main_loop (); |
917 | |
918 shutdown (); | |
914 } | 919 } |
915 } | 920 } |
916 catch (const exit_exception& xe) | 921 catch (const exit_exception& xe) |
917 { | 922 { |
918 exit_status = xe.exit_status (); | 923 exit_status = xe.exit_status (); |
919 } | 924 |
920 | 925 shutdown (); |
921 shutdown (); | 926 } |
922 | 927 |
923 return exit_status; | 928 return exit_status; |
924 } | 929 } |
925 | 930 |
926 // Call a function with exceptions handled to avoid problems with | 931 // Call a function with exceptions handled to avoid problems with |