the cutbuffer if the cutbuffer isn't empty
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2126
35c25a1d-7b9e-4130-9fde-
d3aeb78583b8
buffer rather than the cutbuffer. Changes to backup_lines(),
do_justify(), etc. (DLR)
- cut.c:
+ do_cut_text()
+ - If keep_cutbuffer is FALSE, only blow away the text in the
+ cutbuffer if the cutbuffer isn't empty. (DLR)
do_uncut_text()
- No longer duplicate Pico's adding an extra magicline to the
file if uncutting leaves the cursor on the current one, as
check_statusblank();
- /* If keep_cutbuffer is FALSE, blow away the text in the
- * cutbuffer. */
- if (!keep_cutbuffer) {
+ /* If keep_cutbuffer is FALSE and the cutbuffer isn't empty, blow
+ * away the text in the cutbuffer. */
+ if (!keep_cutbuffer && cutbuffer != NULL) {
free_filestruct(cutbuffer);
cutbuffer = NULL;
#ifdef DEBUG