Skip to content

Commit 391e9f4

Browse files
author
Markus Humm
committed
First attempt on a bugfix for bug #59
Disable overflow checking for the offending line in DECHashBase. But I'm not sure yet this is the right solution. DIscussion in German DP forum has been started.
1 parent 8d79b2c commit 391e9f4

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

Source/DECHashBase.pas

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{*****************************************************************************
1+
{*****************************************************************************
22
The DEC team (see file NOTICE.txt) licenses this file
33
to you under the Apache License, Version 2.0 (the
44
"License"); you may not use this file except in compliance
@@ -554,7 +554,19 @@ procedure TDECHash.Increment8(var Value; Add: UInt32);
554554
else
555555
Carry := False;
556556

557+
{ TODO :
558+
Das wäre eine funktionierende Lösung für Bug #59, Anfrage in DE DP ob das gut ist läuft }
559+
{$IFDEF Q+}
560+
{$define USES_OVERFLOW_CHECKING}
561+
{$ENDIF}
562+
563+
{$Q-}
557564
Value := Value + Add;
565+
566+
{$IFDEF USES_OVERFLOW_CHECKING}
567+
{$Q+}
568+
{$undefine USES_OVERFLOW_CHECKING}
569+
{$ENDIF}
558570
Carry := Carry or (Value < Add); // set Carry Flag on overflow or keep it if already set
559571
end;
560572

0 commit comments

Comments
 (0)