Skip to content

Commit 024baa9

Browse files
committed
[fuchsia] Update process info struct
The fuchsia platform is in the process of softly transitioning over to using a new value for ZX_INFO_PROCESS with a new corresponding struct. This change migrates libstd. See fxrev.dev/510478 and fxbug.dev/30751 for more detail.
1 parent af9b508 commit 024baa9

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

library/std/src/sys/unix/process/zircon.rs

+7-4
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,12 @@ pub const ZX_TASK_TERMINATED: zx_signals_t = ZX_OBJECT_SIGNAL_3;
2525

2626
pub const ZX_RIGHT_SAME_RIGHTS: zx_rights_t = 1 << 31;
2727

28+
// The upper four bits gives the minor version.
2829
pub type zx_object_info_topic_t = u32;
2930

30-
pub const ZX_INFO_PROCESS: zx_object_info_topic_t = 3;
31+
pub const ZX_INFO_PROCESS: zx_object_info_topic_t = 3 | (1 << 28);
32+
33+
pub type zx_info_process_flags_t = u32;
3134

3235
pub fn zx_cvt<T>(t: T) -> io::Result<T>
3336
where
@@ -68,9 +71,9 @@ impl Drop for Handle {
6871
#[repr(C)]
6972
pub struct zx_info_process_t {
7073
pub return_code: i64,
71-
pub started: bool,
72-
pub exited: bool,
73-
pub debugger_attached: bool,
74+
pub start_time: zx_time_t,
75+
pub flags: zx_info_process_flags_t,
76+
pub reserved1: u32,
7477
}
7578

7679
extern "C" {

0 commit comments

Comments
 (0)