Foreground Job Control Overhaul (#661)
Job control in Ion was a complete mess, and it was a wonder that it even worked at one point to begin with! I've gone through and fixed a number of issues related to foreground job management. - Processes are no longer preemptively killed by Ion to emulate SIGPIPE support. - Processes within a pipeline are now assigned the same PGID. - A SIGPIPE handler is now registered so that processes exit when they receive a SIGPIPE. - Jobs should exit with the correct exit statuses in more situations. - External commands now use fork + exec, rather than `std::process::Command`. - Redox's foreground job management was also improved. - Some refactoring was performed, with more refactoring planned in the future. There's likely some issues that remain to be addressed though. Needs more testing & bug reports. Background job management remains to be mostly broken for now, so that's an area to look into next.
Showing
- src/lib/shell/job.rs 24 additions, 40 deletionssrc/lib/shell/job.rs
- src/lib/shell/mod.rs 7 additions, 0 deletionssrc/lib/shell/mod.rs
- src/lib/shell/pipe_exec/job_control.rs 3 additions, 22 deletionssrc/lib/shell/pipe_exec/job_control.rs
- src/lib/shell/pipe_exec/mod.rs 311 additions, 289 deletionssrc/lib/shell/pipe_exec/mod.rs
- src/lib/shell/plugins/library_iter/mod.rs 2 additions, 2 deletionssrc/lib/shell/plugins/library_iter/mod.rs
- src/lib/shell/plugins/mod.rs 1 addition, 0 deletionssrc/lib/shell/plugins/mod.rs
- src/lib/sys/redox.rs 71 additions, 49 deletionssrc/lib/sys/redox.rs
- src/lib/sys/unix/job_control.rs 19 additions, 43 deletionssrc/lib/sys/unix/job_control.rs
- src/lib/sys/unix/mod.rs 24 additions, 8 deletionssrc/lib/sys/unix/mod.rs
Loading
Please register or sign in to comment