mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-14 15:56:13 +03:00
termio/exec: pass code and runtime to error but don't show it yet
This commit is contained in:
@ -816,7 +816,10 @@ fn processExit(
|
|||||||
// Notify our main writer thread which has access to more
|
// Notify our main writer thread which has access to more
|
||||||
// information so it can show a better error message.
|
// information so it can show a better error message.
|
||||||
_ = ev.writer_mailbox.push(.{
|
_ = ev.writer_mailbox.push(.{
|
||||||
.child_exited_abnormally = {},
|
.child_exited_abnormally = .{
|
||||||
|
.code = code,
|
||||||
|
.runtime_ms = runtime,
|
||||||
|
},
|
||||||
}, .{ .forever = {} });
|
}, .{ .forever = {} });
|
||||||
ev.writer_wakeup.notify() catch break :runtime;
|
ev.writer_wakeup.notify() catch break :runtime;
|
||||||
|
|
||||||
|
@ -66,7 +66,10 @@ pub const Message = union(enum) {
|
|||||||
/// as process exited but the surface hasn't been notified to
|
/// as process exited but the surface hasn't been notified to
|
||||||
/// close because termio can use this to update the terminal
|
/// close because termio can use this to update the terminal
|
||||||
/// with an error message.
|
/// with an error message.
|
||||||
child_exited_abnormally: void,
|
child_exited_abnormally: struct {
|
||||||
|
code: u32,
|
||||||
|
runtime_ms: u64,
|
||||||
|
},
|
||||||
|
|
||||||
/// Write where the data fits in the union.
|
/// Write where the data fits in the union.
|
||||||
write_small: WriteReq.Small,
|
write_small: WriteReq.Small,
|
||||||
|
Reference in New Issue
Block a user