mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
[ZOO] Decode attributes.
This commit is contained in:
@@ -107,7 +107,7 @@ public sealed partial class Zoo
|
|||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
public ErrorNumber GetAttributes(int entryNumber, out FileAttributes attributes)
|
public ErrorNumber GetAttributes(int entryNumber, out FileAttributes attributes)
|
||||||
{
|
{
|
||||||
// TODO: Decode them
|
// DOS version of ZOO ignores the attributes, so we just say it's a file
|
||||||
attributes = FileAttributes.None;
|
attributes = FileAttributes.None;
|
||||||
|
|
||||||
if(!Opened) return ErrorNumber.NotOpened;
|
if(!Opened) return ErrorNumber.NotOpened;
|
||||||
@@ -162,6 +162,9 @@ public sealed partial class Zoo
|
|||||||
LastWriteTimeUtc = DateHandlers.DosToDateTime(entry.date, entry.time) // TODO: Handle tz, when not 127
|
LastWriteTimeUtc = DateHandlers.DosToDateTime(entry.date, entry.time) // TODO: Handle tz, when not 127
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// POSIX permissions, DOS version of ZOO basically ignored the attributes
|
||||||
|
if((entry.fattr & 1 << 22) > 0) stat.Mode = entry.fattr & 0x1ff;
|
||||||
|
|
||||||
return ErrorNumber.NoError;
|
return ErrorNumber.NoError;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user