瀏覽代碼

pas2js: fixed globbing * ignoring . and ..

git-svn-id: trunk@37765 -
Mattias Gaertner 8 年之前
父節點
當前提交
effbafabd2
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      utils/pas2js/pas2jsfileutils.pp

+ 1 - 0
utils/pas2js/pas2jsfileutils.pp

@@ -494,6 +494,7 @@ begin
       Path:=LeftStr(Mask,p-1);
       if FindFirst(Path,faAnyFile,Info)=0 then begin
         repeat
+          if (Info.Name='') or (Info.Name='.') or (Info.Name='..') then continue;
           Filename:=ExtractFilePath(Path)+Info.Name;
           if p>length(Mask) then begin
             // e.g. /path/unit*.pas