diff options
Diffstat (limited to 'src/diff.c')
-rw-r--r-- | src/diff.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/diff.c b/src/diff.c index 0a0594cfef..6f25c373c4 100644 --- a/src/diff.c +++ b/src/diff.c @@ -1007,10 +1007,12 @@ check_external_diff(diffio_T *diffio) for (;;) { - // There must be a line that contains "1c1". + // For normal diff there must be a line that contains + // "1c1". For unified diff "@@ -1 +1 @@". if (vim_fgets(linebuf, LBUFLEN, fd)) break; - if (STRNCMP(linebuf, "1c1", 3) == 0) + if (STRNCMP(linebuf, "1c1", 3) == 0 + || STRNCMP(linebuf, "@@ -1 +1 @@", 11) == 0) ok = TRUE; } fclose(fd); |