File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -82,6 +82,7 @@ pub enum StdioContainer {
82
82
}
83
83
84
84
/// Describes the result of a process after it has terminated.
85
+ /// Note that Windows have no signals, so the result is usually ExitStatus.
85
86
#[ deriving( Eq ) ]
86
87
pub enum ProcessExit {
87
88
/// Normal termination with an exit status.
Original file line number Diff line number Diff line change 8
8
// option. this file may not be copied, modified, or distributed
9
9
// except according to those terms.
10
10
11
- // xfail-fast
11
+ // xfail-fast calling itself doesn't work on check-fast
12
12
13
13
use std:: { os, run} ;
14
14
use std:: io:: process;
@@ -20,8 +20,10 @@ fn main() {
20
20
unsafe { * ( 0 as * mut int ) = 0 ; }
21
21
} else {
22
22
let status = run:: process_status ( args[ 0 ] , [ ~"signal"] ) ;
23
+ // Windows does not have signal, so we get exit status 0xC0000028 (STATUS_BAD_STACK).
23
24
match status {
24
- process:: ExitSignal ( _) => { } ,
25
+ process:: ExitSignal ( _) if cfg ! ( unix) => { } ,
26
+ process:: ExitStatus ( 0xC0000028 ) if cfg ! ( windows) => { } ,
25
27
_ => fail ! ( "invalid termination (was not signalled): {:?}" , status)
26
28
}
27
29
}
You can’t perform that action at this time.
0 commit comments