This commit is contained in:
j2969719 2026-05-07 14:20:44 -07:00 committed by GitHub
commit 9423bbd276
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 16 additions and 1 deletions

View file

@ -609,6 +609,21 @@ begin
if FOutputParser.OpenError and (AFileList.Count < 1) then
raise EFileSourceException.Create(rsMsgErrEOpen);
// fix dir items w/o attr
if (mafFixDirAttr in FMultiArcItem.FFlags) then
begin
for I:= 0 to AFileList.Count - 1 do
begin
ArchiveItem := TArchiveItem(AFileList.Items[I]);
if (ArchiveItem.Attributes = 0) and
(FAllDirsList.Find(ArchiveItem.FileName) > -1) then
begin
ArchiveItem.Attributes := FDirectoryAttribute;
FExistsDirList.Add(ArchiveItem.FileName);
end;
end;
end;
(* if archiver does not give a list of folders *)
for I := 0 to FAllDirsList.Count - 1 do
begin

View file

@ -40,7 +40,7 @@ const
MAF_WIN_ATTR = 8; // Use Windows file attributes
type
TMultiArcFlag = (mafFileNameList, mafHide);
TMultiArcFlag = (mafFileNameList, mafHide, mafFixDirAttr);
TMultiArcFlags = set of TMultiArcFlag;
type