Commit 95add8da authored by Chris Allegretta's avatar Chris Allegretta
Browse files

2008-10-20 Chris Allegretta <chrisa@asty.org>

        * files.c (do_writeout): Add check for file modification when saving
          the file so the user can at least know they may be blowing away changes.



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4344 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
parent 973addcd
Showing with 11 additions and 0 deletions
+11 -0
2008-10-20 Chris Allegretta <chrisa@asty.org>
* files.c (do_writeout): Add check for file modification when saving
the file so the user can at least know they may be blowing away changes.
2008-10-14 Chris Allegretta <chrisa@asty.org>
* nanorc.5: Fix redo man page entry and update explanation, reported by
Eitan Adler <eitanadlerlist@gmail.com>
......
......@@ -2028,6 +2028,13 @@ bool do_writeout(bool exiting)
continue;
}
}
if (openfile->current_stat && openfile->current_stat->st_mtime < st.st_mtime) {
i = do_yesno_prompt(FALSE,
_("File was modified since you opened it, continue saving ? "));
if (i == 0 || i == -1)
continue;
}
}
/* Convert newlines to nulls, just before we save the
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment