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 fact, this attribute completely determines whether a File::Permissions has the read bits, because #13233 isn't implemented yet.
BSD-like systems, including Darwin, also have several file attributes in the LibC::Stat#st_flags that may make a file read-only. All have UF_IMMUTABLE = 0x00000002 and SF_IMMUTABLE = 0x00020000. FreeBSD additionally has UF_READONLY = 0x00001000, that maps to the Windows attribute above, but that attribute seems to have no real effect. Should those flags be reflected in File::Info#permissions? Should Windows do it in the first place?
The text was updated successfully, but these errors were encountered:
On Windows, a file has read permissions if it doesn't have the read-only file attribute set:
crystal/src/crystal/system/win32/file_info.cr
Lines 34 to 39 in 62f27b2
In fact, this attribute completely determines whether a
File::Permissions
has the read bits, because #13233 isn't implemented yet.BSD-like systems, including Darwin, also have several file attributes in the
LibC::Stat#st_flags
that may make a file read-only. All haveUF_IMMUTABLE = 0x00000002
andSF_IMMUTABLE = 0x00020000
. FreeBSD additionally hasUF_READONLY = 0x00001000
, that maps to the Windows attribute above, but that attribute seems to have no real effect. Should those flags be reflected inFile::Info#permissions
? Should Windows do it in the first place?The text was updated successfully, but these errors were encountered: