summaryrefslogtreecommitdiff
path: root/UCore.pas
diff options
context:
space:
mode:
Diffstat (limited to 'UCore.pas')
-rw-r--r--UCore.pas9
1 files changed, 5 insertions, 4 deletions
diff --git a/UCore.pas b/UCore.pas
index b4425c3..cc6929f 100644
--- a/UCore.pas
+++ b/UCore.pas
@@ -28,7 +28,7 @@ function FillPanel(List: TList; ListView: TGTKListView; Engine: TPanelEngine; Le
procedure FindNextSelected(ListView: TGTKListView; DataList: TList; var Item1, Item2: string);
procedure UnselectAll(ListView: TGTKListView; DataList: TList);
-procedure FillDirFiles(Engine: TPanelEngine; DestList: TList; InputFiles: TStringList; DoNotRecurse, SortForStream: boolean);
+procedure FillDirFiles(Engine: TPanelEngine; DestList: TList; InputFiles: TStringList; DoNotRecurse, SortForStream: boolean; InaccessiblePaths: TStringList);
function GetFileInfoSL(Engine: TPanelEngine; const APath: string): PDataItemSL;
procedure DebugWriteListSL(List: TList);
@@ -348,7 +348,7 @@ end;
(********************************************************************************************************************************)
(********************************************************************************************************************************)
-procedure FillDirFiles(Engine: TPanelEngine; DestList: TList; InputFiles: TStringList; DoNotRecurse, SortForStream: boolean);
+procedure FillDirFiles(Engine: TPanelEngine; DestList: TList; InputFiles: TStringList; DoNotRecurse, SortForStream: boolean; InaccessiblePaths: TStringList);
var DirStage1List, FilesList, DirStage2List: TList;
function FillDirFiles_compare_func(Item1, Item2: Pointer): integer;
@@ -442,7 +442,7 @@ var DirStage1List, FilesList, DirStage2List: TList;
if Engine.ChangeDir(ParentDir, @Error) then
FillDirFiles_Recurse(ParentDir, ALevel + 1)
else begin
- // * TODO: report and handle errors? we should make sure that user knows some of his data won't be copied
+ InaccessiblePaths.Add(ParentDir);
DebugMsg(['*** FillDirFiles_Recurse: error changing dir to ''', LocalPath, ''': ', Error^.message]);
g_error_free(Error);
end;
@@ -454,7 +454,7 @@ var DirStage1List, FilesList, DirStage2List: TList;
end;
end;
end else begin
- // * TODO: report and handle errors? we should make sure that user knows some of his data won't be copied
+ InaccessiblePaths.Add(LocalPath);
DebugMsg(['*** FillDirFiles_Recurse: error getting listing of ''', LocalPath, ''': ', Error^.message]);
g_error_free(Error);
// Clear remaining items (in case of error)
@@ -477,6 +477,7 @@ begin
for i := 0 to InputFiles.Count - 1 do begin
root := GetFileInfoSL(Engine, InputFiles[i]);
if (root = nil) then begin
+ InaccessiblePaths.Add(InputFiles[i]);
DebugMsg(['FillDirFiles: cannot stat ', InputFiles[i]]);
Exit;
end;