Show More
@@ -264,16 +264,11 b' static int diff(struct line *a, int an, ' | |||
|
264 | 264 | if (!next) |
|
265 | 265 | break; |
|
266 | 266 | |
|
267 | if (curr->a2 == next->a1) | |
|
267 | if (curr->a2 == next->a1 || curr->b2 == next->b1) | |
|
268 | 268 | while (curr->a2 + shift < an && curr->b2 + shift < bn |
|
269 | 269 | && !cmp(a + curr->a2 + shift, |
|
270 | 270 | b + curr->b2 + shift)) |
|
271 | 271 | shift++; |
|
272 | else if (curr->b2 == next->b1) | |
|
273 | while (curr->b2 + shift < bn && curr->a2 + shift < an | |
|
274 | && !cmp(b + curr->b2 + shift, | |
|
275 | a + curr->a2 + shift)) | |
|
276 | shift++; | |
|
277 | 272 | if (!shift) |
|
278 | 273 | continue; |
|
279 | 274 | curr->b2 += shift; |
General Comments 0
You need to be logged in to leave comments.
Login now