mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-09-04 10:11:46 +03:00
fix(tui): preserve shell after Ctrl+C (#5502)
This commit is contained in:
+4
-1
@@ -1653,7 +1653,10 @@ export class NanobotTui {
|
||||
this.clearComposer()
|
||||
this.status.content = this.readyStatus()
|
||||
} else {
|
||||
this.quit()
|
||||
// Finish dispatching the raw ETX before destroy() restores terminal input.
|
||||
// Releasing the terminal from inside this callback can leak the same Ctrl+C
|
||||
// to the parent shell on Windows terminals.
|
||||
setTimeout(() => this.quit(), 0)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user