mirror of
https://gitlab.com/freepascal.org/fpc/pas2js.git
synced 2025-09-13 09:30:41 +02:00
* Allow seconds to be empty
This commit is contained in:
parent
1a5c3bba66
commit
07d4e4a9fe
@ -2442,8 +2442,11 @@ begin
|
|||||||
begin
|
begin
|
||||||
lH:=StrToIntDef(Copy(AValue,P[ppHour],2),-1);
|
lH:=StrToIntDef(Copy(AValue,P[ppHour],2),-1);
|
||||||
lMi:=StrToIntDef(Copy(AValue,P[ppMinute],2),-1);
|
lMi:=StrToIntDef(Copy(AValue,P[ppMinute],2),-1);
|
||||||
lS:=StrToIntDef(Copy(AValue,P[ppSec],2),-1);
|
// Bug ID 37974
|
||||||
|
if (Length(AValue)>=P[ppSec]) then
|
||||||
|
lS:=StrToIntDef(Copy(AValue,P[ppSec],2),-1)
|
||||||
|
else
|
||||||
|
LS:=0;
|
||||||
if (Length(AValue)>=P[ppMSec]) then
|
if (Length(AValue)>=P[ppMSec]) then
|
||||||
lmS := StrToIntDef(Copy(AValue,P[ppMSec],3),-1);
|
lmS := StrToIntDef(Copy(AValue,P[ppMSec],3),-1);
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user