@@ -118,31 +118,38 @@ impl WaitStatus {
118118}
119119
120120fn exited ( status : i32 ) -> bool {
121- libc:: WIFEXITED ( status)
121+ #[ allow( unused_unsafe) ]
122+ unsafe { libc:: WIFEXITED ( status) }
122123}
123124
124125fn exit_status ( status : i32 ) -> i32 {
125- libc:: WEXITSTATUS ( status)
126+ #[ allow( unused_unsafe) ]
127+ unsafe { libc:: WEXITSTATUS ( status) }
126128}
127129
128130fn signaled ( status : i32 ) -> bool {
129- libc:: WIFSIGNALED ( status)
131+ #[ allow( unused_unsafe) ]
132+ unsafe { libc:: WIFSIGNALED ( status) }
130133}
131134
132135fn term_signal ( status : i32 ) -> Result < Signal > {
133- Signal :: try_from ( libc:: WTERMSIG ( status) )
136+ #[ allow( unused_unsafe) ]
137+ Signal :: try_from ( unsafe { libc:: WTERMSIG ( status) } )
134138}
135139
136140fn dumped_core ( status : i32 ) -> bool {
137- libc:: WCOREDUMP ( status)
141+ #[ allow( unused_unsafe) ]
142+ unsafe { libc:: WCOREDUMP ( status) }
138143}
139144
140145fn stopped ( status : i32 ) -> bool {
141- libc:: WIFSTOPPED ( status)
146+ #[ allow( unused_unsafe) ]
147+ unsafe { libc:: WIFSTOPPED ( status) }
142148}
143149
144150fn stop_signal ( status : i32 ) -> Result < Signal > {
145- Signal :: try_from ( libc:: WSTOPSIG ( status) )
151+ #[ allow( unused_unsafe) ]
152+ Signal :: try_from ( unsafe { libc:: WSTOPSIG ( status) } )
146153}
147154
148155#[ cfg( any( target_os = "android" , target_os = "linux" ) ) ]
@@ -151,7 +158,8 @@ fn syscall_stop(status: i32) -> bool {
151158 // of delivering SIGTRAP | 0x80 as the signal number for syscall
152159 // stops. This allows easily distinguishing syscall stops from
153160 // genuine SIGTRAP signals.
154- libc:: WSTOPSIG ( status) == libc:: SIGTRAP | 0x80
161+ #[ allow( unused_unsafe) ]
162+ unsafe { libc:: WSTOPSIG ( status) == libc:: SIGTRAP | 0x80 }
155163}
156164
157165#[ cfg( any( target_os = "android" , target_os = "linux" ) ) ]
@@ -160,7 +168,8 @@ fn stop_additional(status: i32) -> c_int {
160168}
161169
162170fn continued ( status : i32 ) -> bool {
163- libc:: WIFCONTINUED ( status)
171+ #[ allow( unused_unsafe) ]
172+ unsafe { libc:: WIFCONTINUED ( status) }
164173}
165174
166175impl WaitStatus {
0 commit comments