CRITICAL FIX: Change exit 0 to return 0 to prevent closing terminal session
ISSUE: When exiting the launcher (option 0), the script called exit 0 which closed the entire shell session, disconnecting SSH/tmux and crashing the terminal. FIX: Changed line 721 from 'exit 0' to 'return 0' - exit 0 = closes entire shell - return 0 = returns from main() function, launcher exits cleanly - Shell/SSH session remains open Testing: - Launcher now exits cleanly without closing terminal - SSH sessions no longer disconnected - tmux sessions no longer crash - User returns to shell prompt safely Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
+2
-2
@@ -715,10 +715,10 @@ main() {
|
||||
echo ""
|
||||
else
|
||||
echo ""
|
||||
echo -e "${GREEN}Thanks for using Server Management Toolkit!${NC}"
|
||||
echo "Thanks for using Server Management Toolkit!"
|
||||
echo ""
|
||||
fi
|
||||
exit 0
|
||||
return 0
|
||||
;;
|
||||
*)
|
||||
echo -e "${RED}Invalid option${NC}"
|
||||
|
||||
Reference in New Issue
Block a user