Pārlūkot izejas kodu

SysInfo some changes

Unknown 5 gadi atpakaļ
vecāks
revīzija
fec7b561c7
1 mainītis faili ar 10 papildinājumiem un 1 dzēšanām
  1. 10 1
      Quick.SysInfo.pas

+ 10 - 1
Quick.SysInfo.pas

@@ -122,6 +122,15 @@ begin
 end;
 end;
 
 
 initialization
 initialization
-  SystemInfo.GetInfo;
+  try
+    SystemInfo.GetInfo;
+  except
+    {$IFDEF MSWINDOWS}
+    on E : Exception do
+    begin
+      if (not IsLibrary) and (not IsService) then raise Exception.CreateFmt('Error getting SystemInfo: %s',[e.Message]);
+    end;
+    {$ENDIF}
+  end;
 
 
 end.
 end.