From 1b7e035dafac3013f5164d4ea6b316e51895137b Mon Sep 17 00:00:00 2001 From: MDW Date: Sun, 3 Sep 2023 21:49:47 +0200 Subject: [PATCH] Fix initialisation of array for $seps --- Text/Diff/Engine/native.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Text/Diff/Engine/native.php b/Text/Diff/Engine/native.php index 73c6c3f..ee3b533 100644 --- a/Text/Diff/Engine/native.php +++ b/Text/Diff/Engine/native.php @@ -233,7 +233,7 @@ function _diag($xoff, $xlim, $yoff, $ylim, $nchunks) } } - $seps[] = $flip ? array($yoff, $xoff) : array($xoff, $yoff); + $seps = array($flip ? array($yoff, $xoff) : array($xoff, $yoff)); $ymid = $ymids[$this->lcs]; for ($n = 0; $n < $nchunks - 1; $n++) { $x1 = $xoff + (int)(($numer + ($xlim - $xoff) * $n) / $nchunks);