diff options
author | Bram Moolenaar <Bram@vim.org> | 2005-09-25 22:16:38 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2005-09-25 22:16:38 +0000 |
commit | 1e01546026ce909b5fe56c05867f28e77d1b6eb3 (patch) | |
tree | 05ccef65c430097352670acbbeb5520d649ba841 /src/diff.c | |
parent | bfd8fc0529f46612f7b3efca6c7b3305e70ac374 (diff) | |
download | vim-git-1e01546026ce909b5fe56c05867f28e77d1b6eb3.tar.gz |
updated for version 7.0150
Diffstat (limited to 'src/diff.c')
-rw-r--r-- | src/diff.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/diff.c b/src/diff.c index b6f936e8f..1a382e399 100644 --- a/src/diff.c +++ b/src/diff.c @@ -1905,7 +1905,10 @@ ex_diffgetput(eap) { /* No argument: Find the other buffer in the list of diff buffers. */ for (idx_other = 0; idx_other < DB_COUNT; ++idx_other) - if (diffbuf[idx_other] != curbuf && diffbuf[idx_other] != NULL) + if (diffbuf[idx_other] != curbuf + && diffbuf[idx_other] != NULL + && (eap->cmdidx != CMD_diffput + || diffbuf[idx_other]->b_p_ma)) break; if (idx_other == DB_COUNT) { @@ -1915,7 +1918,9 @@ ex_diffgetput(eap) /* Check that there isn't a third buffer in the list */ for (i = idx_other + 1; i < DB_COUNT; ++i) - if (diffbuf[i] != curbuf && diffbuf[i] != NULL) + if (diffbuf[i] != curbuf + && diffbuf[i] != NULL + && (eap->cmdidx != CMD_diffput || diffbuf[i]->b_p_ma)) { EMSG(_("E101: More than two buffers in diff mode, don't know which one to use")); return; |