Bug in Diff.pas comparing characters.
Hi Jesús
The diff.pas from Jedi code format has a bug when comparing strings.I had not corrected it since we do not use it in JCF and it does not affect us.
Now I backported the change from the original source of Diff.pas [TextDiff]https://github.com/rickard67/TextDiff)
Also you can see [lazarus forum]https://forum.lazarus.freepascal.org/index.php/topic,62219.30.html)
The bug is in Execute function comparing chars. String are 1 based.
//finally, append any trailing matches onto compareList ...
with FLastCompareRec do
begin
- AddChangeChr(oldIndex1,len1Minus1-oldIndex1, ckNone);
+ AddChangeChr(oldIndex1,len1Minus1-oldIndex1+1, ckNone);
end;
finally
FExecuting := false;
You are doing an awesome work with this git wrapper.
Saludos Domingo.