FIX: Process symlinks (Windows)

This commit is contained in:
Alexander Koblov 2018-03-06 19:24:30 +00:00
commit 019b0ffb66
2 changed files with 9 additions and 9 deletions

View file

@ -74,12 +74,7 @@ begin
FStatistics.CurrentFile := aFile.Path + aFile.Name;
UpdateStatistics(FStatistics);
if aFile.IsDirectory then
begin
Inc(FStatistics.Directories);
ProcessSubDirs(aFile.Path + aFile.Name + DirectorySeparator);
end
else if aFile.IsLink then
if aFile.IsLink then
begin
Inc(FStatistics.Links);
@ -107,6 +102,11 @@ begin
end;
end;
end
else if aFile.IsDirectory then
begin
Inc(FStatistics.Directories);
ProcessSubDirs(aFile.Path + aFile.Name + DirectorySeparator);
end
else
begin
// Not always this will be regular file (on Unix can be socket, FIFO, block, char, etc.)

View file

@ -254,10 +254,10 @@ begin
end;
end;
if aFile.IsDirectory then
AddDirectory(aFile, CurrentNode)
else if aFile.IsLink then
if aFile.IsLink then
DecideOnLink(aFile, CurrentNode)
else if aFile.IsDirectory then
AddDirectory(aFile, CurrentNode)
else
AddFile(aFile, CurrentNode);
end;