On Di, 14 Okt 2014, Nikola Petrov wrote:

> I found the following issue with vimdiff. I want to %diffput the left
> hand side from vimdiff to the right hand side. This has the side effect
> of adding 1 additional blank line which is a problem for the workflow I
> am currently using vimdiff for. I can reproduce this with
> 
>     vimdiff -u NONE
> 
> so it is not something related to my configuration.

I only see this when diffing with an empty file and this seems to be 
fixed by

diff --git a/src/diff.c b/src/diff.c
--- a/src/diff.c
+++ b/src/diff.c
@@ -2327,7 +2327,7 @@ ex_diffgetput(eap)

            buf_empty = FALSE;
            added = 0;
-           for (i = 0; i < count; ++i)
+           for (i = 0; i <= count; ++i)
            {
                /* remember deleting the last line of the buffer */
                buf_empty = curbuf->b_ml.ml_line_count == 1;


Best,
Christian
-- 
Wahrhaftigkeit ist die größte List.
                -- Georg Christoph Lichtenberg

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui