Skip to content

Recent changes broke stat()? #20

@timwoj

Description

@timwoj

I think the recent changes that moved stat() and redefined the sizes of some of the fields in struct stat (both in posix_stdio.h) might have broken st_mode. If you call it on a directory, I'm getting st_mode set to 2. It should instead have the 0x4000 bit set so that S_ISDIR works correctly. Changing struct stat back to use the version with _dev_t and _ino_t (the one wrapped in #if 0 is posix_stdio.h) fixes it, but it loses the two block-related fields.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions