mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
updated for version 7.0-195
This commit is contained in:
parent
ad40f02cd9
commit
373154b00c
@ -1242,14 +1242,22 @@ autowrite(buf, forceit)
|
||||
buf_T *buf;
|
||||
int forceit;
|
||||
{
|
||||
int r;
|
||||
|
||||
if (!(p_aw || p_awa) || !p_write
|
||||
#ifdef FEAT_QUICKFIX
|
||||
/* never autowrite a "nofile" or "nowrite" buffer */
|
||||
|| bt_dontwrite(buf)
|
||||
/* never autowrite a "nofile" or "nowrite" buffer */
|
||||
|| bt_dontwrite(buf)
|
||||
#endif
|
||||
|| (!forceit && buf->b_p_ro) || buf->b_ffname == NULL)
|
||||
|| (!forceit && buf->b_p_ro) || buf->b_ffname == NULL)
|
||||
return FAIL;
|
||||
return buf_write_all(buf, forceit);
|
||||
r = buf_write_all(buf, forceit);
|
||||
|
||||
/* Writing may succeed but the buffer still changed, e.g., when there is a
|
||||
* conversion error. We do want to return FAIL then. */
|
||||
if (buf_valid(buf) && bufIsChanged(buf))
|
||||
r = FAIL;
|
||||
return r;
|
||||
}
|
||||
|
||||
/*
|
||||
@ -1472,6 +1480,8 @@ check_changed_any(hidden)
|
||||
if (buf == NULL) /* No buffers changed */
|
||||
return FALSE;
|
||||
|
||||
/* Try auto-writing the buffer. If this fails but the buffer no
|
||||
* longer exists it's not changed, that's OK. */
|
||||
if (check_changed(buf, p_awa, TRUE, FALSE, TRUE) && buf_valid(buf))
|
||||
break; /* didn't save - still changes */
|
||||
}
|
||||
|
@ -666,6 +666,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
195,
|
||||
/**/
|
||||
194,
|
||||
/**/
|
||||
|
Loading…
x
Reference in New Issue
Block a user