소스 검색

ppudump: catch exception on illegal datetime (mainly cross compiled units)

git-svn-id: trunk@45219 -
marcus 5 년 전
부모
커밋
4d71051859
1개의 변경된 파일6개의 추가작업 그리고 3개의 파일을 삭제
  1. 6 3
      compiler/utils/ppuutils/ppudump.pp

+ 6 - 3
compiler/utils/ppuutils/ppudump.pp

@@ -4762,9 +4762,12 @@ begin
                    with TPpuSrcFile.Create(CurUnit.SourceFiles) do begin
                      Name:=getstring;
                      i:=getlongint;
-                     if i >= 0 then
-                       FileTime:=FileDateToDateTime(i);
-                     Writeln(['Source file ',sourcenumber,' : ',Name,' ',filetimestring(i)]);
+                     try
+                       if i >= 0 then
+                         FileTime:=FileDateToDateTime(i);
+                       Writeln(['Source file ',sourcenumber,' : ',Name,' ',filetimestring(i)]);
+                     except
+                     end;
                    end;
 
                    inc(sourcenumber);