Skip to content

Nit: UF_HIDDEN causes st_flags to get dropped #69004

@danmoseley

Description

@danmoseley

@tmds pointed out that we accidentally blow away all other flags returned by stat if UF_HIDDEN is set

dst->UserFlags = ((src->st_flags & UF_HIDDEN) == UF_HIDDEN) ? PAL_UF_HIDDEN : 0;

I still haven't received a mac, so I don't know what these might be, but this answer suggests some. they may be irrelevant currently, but we should fix this line.

Also, we are missing a static assert here to verify that UF_HIDDEN == PAL_UF_HIDDEN

c_static_assert(PAL_S_IFMT == S_IFMT);

which we need, since we assume they remain equal both here


and because there is no matching code in SystemNative_FChflags and SystemNative_LChflags to map back to the system UF_HIDDEN.

Metadata

Metadata

Labels

area-System.IOhelp wanted[up-for-grabs] Good issue for external contributorsin-prThere is an active PR which will close this issue when it is merged

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions