Browse Source

* fix for DateTimeToJulianDate and JulianDateToDateTime for integer=smallint

git-svn-id: trunk@27103 -
nickysn 11 years ago
parent
commit
c88cebfc97
1 changed files with 2 additions and 2 deletions
  1. 2 2
      packages/rtl-objpas/src/inc/dateutil.inc

+ 2 - 2
packages/rtl-objpas/src/inc/dateutil.inc

@@ -2044,7 +2044,7 @@ end;
 Function DateTimeToJulianDate(const AValue: TDateTime): Double;
 var
   day,month,year: word;
-  a,y,m: integer;
+  a,y,m: longint;
 begin
   DecodeDate ( AValue, year, month, day );
   a := (14-month) div 12;
@@ -2064,7 +2064,7 @@ end;
 
 Function TryJulianDateToDateTime(const AValue: Double; out ADateTime: TDateTime): Boolean;
 var
-  a,b,c,d,e,m:integer;
+  a,b,c,d,e,m:longint;
   day,month,year: word;
 begin
   a := trunc(AValue + 32044.5);