File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -187,6 +187,13 @@ pub trait ExitStatusExt {
187187 #[ unstable( feature = "unix_process_wait_more" , issue = "none" ) ]
188188 fn stopped_signal ( & self ) -> Option < i32 > ;
189189
190+ /// Whether the process was continued from a stopped status.
191+ ///
192+ /// Ie, `WIFCONTINUED`. This is only possible if the status came from a `wait` system call
193+ /// which was passed `WCONTINUED`, was then converted into an `ExitStatus`.
194+ #[ unstable( feature = "unix_process_wait_more" , issue = "none" ) ]
195+ fn continued ( & self ) -> bool ;
196+
190197 /// Returns the underlying raw `wait` status.
191198 #[ unstable( feature = "unix_process_wait_more" , issue = "none" ) ]
192199 fn into_raw ( self ) -> i32 ;
@@ -210,6 +217,10 @@ impl ExitStatusExt for process::ExitStatus {
210217 self . as_inner ( ) . stopped_signal ( )
211218 }
212219
220+ fn continued ( & self ) -> bool {
221+ self . as_inner ( ) . continued ( )
222+ }
223+
213224 fn into_raw ( self ) -> i32 {
214225 self . as_inner ( ) . into_raw ( ) . into ( )
215226 }
Original file line number Diff line number Diff line change @@ -490,6 +490,10 @@ impl ExitStatus {
490490 if libc:: WIFSTOPPED ( self . 0 ) { Some ( libc:: WSTOPSIG ( self . 0 ) ) } else { None }
491491 }
492492
493+ pub fn continued ( & self ) -> bool {
494+ libc:: WIFCONTINUED ( self . 0 )
495+ }
496+
493497 pub fn into_raw ( & self ) -> c_int {
494498 self . 0
495499 }
You can’t perform that action at this time.
0 commit comments