You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this PR: #52235 there were a couple of non-urgent issues that we can address separately from that PR:
Fix: FileSystemEntry.Attributes property is not correct on Unix #52235 (comment) Use StartsWith instead of a manual check of length+first char, when checking if a filename is hidden because it starts with a dot. This method is only reached when the user explicitly checks the hidden value of a file/folder, but not on the most common enumeration scenarios.
Fix: FileSystemEntry.Attributes property is not correct on Unix #52235 (comment) When verifying the value of the read-only flag of a file/folder, we always check the values of GetEUid and GetEGid, which are p/invokes. The cases where these are accessed do not have a direct impact in the most common enumeration scenarios, but it would be nice to cache them and make sure their values get refreshed if the user requests doing so, or the file cache is uninitialized.
Fix: FileSystemEntry.Attributes property is not correct on Unix #52235 (comment) Consider reusing IsNameHidden when checking for the dot in FileSystemEntry.Initialize. A ROS<char> needs to be created from the byte*, and we need to check if aggressive inlining could help with any potential perf hit from calling two new methods.
In this PR: #52235 there were a couple of non-urgent issues that we can address separately from that PR:
StartsWithinstead of a manual check of length+first char, when checking if a filename is hidden because it starts with a dot. This method is only reached when the user explicitly checks the hidden value of a file/folder, but not on the most common enumeration scenarios.GetEUidandGetEGid, which are p/invokes. The cases where these are accessed do not have a direct impact in the most common enumeration scenarios, but it would be nice to cache them and make sure their values get refreshed if the user requests doing so, or the file cache is uninitialized.FileSystemEntry.Initialize, make sure to put the check forsymlinkin anelse ifinstead of anif, since having either unknown or symlink are mutually exclusive cases.IsNameHiddenwhen checking for the dot inFileSystemEntry.Initialize. AROS<char>needs to be created from thebyte*, and we need to check if aggressive inlining could help with any potential perf hit from calling two new methods.Edit. I followed up in the same PR.