-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Open
Labels
C-bugCategory: This is a bug.Category: This is a bug.O-fuchsiaOperating system: FuchsiaOperating system: FuchsiaT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
Relevant compiler test: https://github.com/rust-lang/rust/blob/master/src/test/ui/process/process-spawn-nonexistent.rs#L14
use std::io::ErrorKind;
use std::process::Command;
fn main() {
let result = Command::new("nonexistent").spawn().unwrap_err().kind();
assert!(matches!(
result,
ErrorKind::NotFound | ErrorKind::PermissionDenied
));
}
The resulting value for result
is -25
, which aligns with the Zircon error ZX_ERR_NOT_FOUND = -25
. This does not align with expected Rust-friendly return value.
Relevant code section is at
pub fn zx_cvt<T>(t: T) -> io::Result<T> |
cc. @tmandry
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.O-fuchsiaOperating system: FuchsiaOperating system: FuchsiaT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.