diff-match-patch icon indicating copy to clipboard operation
diff-match-patch copied to clipboard

Diff.ToString() throws a NullReferenceException

Open dafbyte opened this issue 2 years ago • 0 comments

The C# implementation doesn't consider null value for the text field.

The following line shows how to reproduce. This will not raise a warning on .NET Framework variations (v2.0, v3.x, v4.x).

Diff diff = new Diff(Operation.EQUAL, null);
string actualString = diff.ToString();

dafbyte avatar Mar 21 '23 13:03 dafbyte