Skip to content

Commit

Permalink
Merge pull request #4222 from no1wudi/main
Browse files Browse the repository at this point in the history
Fixes for NuttX target
  • Loading branch information
tgross35 authored Dec 31, 2024
2 parents 4869273 + cb668df commit da95caa
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/unix/nuttx/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ s! {

pub struct passwd {
pub pw_name: *const c_char,
pub pw_passwd: *const c_char,
pub pw_uid: u32,
pub pw_gid: u32,
pub pw_gecos: *const c_char,
Expand Down Expand Up @@ -128,7 +129,7 @@ s! {
pub tm_yday: i32,
pub tm_isdst: i32,
pub tm_gmtoff: isize,
pub tm_zone: *const i8,
pub tm_zone: *const c_char,
__reserved: [usize; __DEFAULT_RESERVED_SIZE__],
}

Expand Down Expand Up @@ -165,7 +166,7 @@ s! {

pub struct dirent {
pub d_type: u8,
pub d_name: [i8; __NAME_MAX__ + 1],
pub d_name: [c_char; __NAME_MAX__ + 1],
}

pub struct fd_set {
Expand Down Expand Up @@ -247,6 +248,7 @@ s! {
// for example, struct passwd, https://pubs.opengroup.org/onlinepubs/009695399/basedefs/pwd.h.html,
// POSIX only defines following fields in struct passwd:
// char *pw_name User's login name.
// char *pw_passwd Encrypted password.
// uid_t pw_uid Numerical user ID.
// gid_t pw_gid Numerical group ID.
// char *pw_dir Initial working directory.
Expand Down

0 comments on commit da95caa

Please sign in to comment.