mirror of
https://github.com/fankes/termux-app.git
synced 2025-09-04 17:55:36 +08:00
Assure "Process completed" string is written to terminal before session is finished
This commit is contained in:
@@ -340,7 +340,6 @@ public final class TerminalSession extends TerminalOutput {
|
||||
if (msg.what == MSG_PROCESS_EXITED) {
|
||||
int exitCode = (Integer) msg.obj;
|
||||
cleanupResources(exitCode);
|
||||
mClient.onSessionFinished(TerminalSession.this);
|
||||
|
||||
String exitDescription = "\r\n[Process completed";
|
||||
if (exitCode > 0) {
|
||||
@@ -355,6 +354,8 @@ public final class TerminalSession extends TerminalOutput {
|
||||
byte[] bytesToWrite = exitDescription.getBytes(StandardCharsets.UTF_8);
|
||||
mEmulator.append(bytesToWrite, bytesToWrite.length);
|
||||
notifyScreenUpdate();
|
||||
|
||||
mClient.onSessionFinished(TerminalSession.this);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user