Skip to content

Wrong getpwent_r and getgrent_r definitions on illumos and solaris #2908

@SteveLauC

Description

@SteveLauC

Definitions according to their man pages:

struct passwd *getpwent_r(struct passwd *pwd, char  *buffer, int buflen);
struct group *getgrent_r(struct group  *grp,  char  *buffer, int bufsize);

libc exposes them as:

pub unsafe extern "C" fn getgrent_r(
    grp: *mut group,
    buf: *mut c_char,
    buflen: size_t,
    result: *mut *mut group
) -> c_int

pub unsafe extern "C" fn getpwent_r( 
    pwd: *mut passed, 
    buf: *mut c_char, 
    buflen: size_t, 
    result: *mut *mut passed
) -> c_int

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions