Bram Moolenaar <[email protected]> wrote:

> Patch 8.1.1049
> Problem:    When user tries to exit with CTRL-C message is confusing.
> Solution:   Only mention ":qa!" when there is a changed buffer. (closes #4163)
> Files:      src/undo.c, src/proto/undo.pro, src/normal.c,
>             src/testdir/test_normal.vim
>
>
> *** ../vim-8.1.1048/src/undo.c  2019-02-17 17:44:36.223875455 +0100
> --- src/undo.c  2019-03-25 21:52:25.512531373 +0100
> ***************
> *** 3531,3536 ****
> --- 3531,3549 ----
>   }
>
>   /*
> +  * Return TRUE if any buffer has changes.  Also buffers that are not 
> written.
> +  */
> +     int
> + anyBufIsChanged(void)
> + {
> +     buf_T *buf;
> +
> +     FOR_ALL_BUFFERS(buf)
> +       if (bufIsChanged(buf))
> +           return TRUE;
> + }
> +
> + /*
>    * Like bufIsChanged() but ignoring a terminal window.
>    */

This gives a compilation warning using gcc-7.3:

undo.c: In function ‘anyBufIsChanged’:
undo.c:3544:1: warning: control reaches end of non-void function [-Wreturn-type]
 }
 ^

It's missing "return FALSE" at the end of the loop.

Dominique

-- 
-- 
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