Skip to content

android: Can we use proper libc typedefs in stat definition? #3285

Open
@danielocfb

Description

@danielocfb

If we look at the stat type's definition for different platforms, we see:

st_dev: dev_t
st_ino: ino_t
[...]

But for arm-linux-androideabi we stop using libc typedefs and instead have:

st_dev: c_ulonglong
st_mode: c_uint
[...]
st_ino: c_ulonglong

Is there a (good) reason for this divergence? If I look at ino_t it's actually defined to be a c_ulong, not c_ulonglong, so that will lead to mismatches all over the place when the typedefs are used. Is this mandated somewhere, a bug in the platform definition that we need to support? This is a nightmare to support in user code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: bug

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions