nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit aff252aed63423d506647ad9a072f495cab83419
parent 08d9f572a44e704376a6c4161f9dbcc1560469da
Author: Benno Schulenberg <bensberg@justemail.net>
Date:   Fri, 10 Jul 2015 17:42:32 +0000

Removing two lines of dead code.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5291 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

Diffstat:
MChangeLog | 1+
Msrc/files.c | 10++--------
2 files changed, 3 insertions(+), 8 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -5,6 +5,7 @@ * src/nano.c (do_toggle): Elide an unneeded variable. * src/files.c: Unwrap some lines and rewrap some others in a more congenial manner; tweak some comments and whitespace and braces. + * src/files.c (read_line): Remove two lines of dead code. 2015-07-06 Benno Schulenberg <bensberg@justemail.net> * src/global.c (add_to_sclist), src/help.c (help_init), src/nano.h, diff --git a/src/files.c b/src/files.c @@ -587,19 +587,13 @@ filestruct *read_line(char *buf, filestruct *prevnode, bool #endif if (*first_line_ins) { - /* Special case: We're inserting with the cursor on the first - * line. */ + /* Special case: we're inserting into the first line. */ fileptr->prev = NULL; fileptr->next = openfile->fileage; fileptr->lineno = 1; - if (*first_line_ins) { *first_line_ins = FALSE; - /* If we're inserting into the first line of the file, then - * we want to make sure that our edit buffer stays on the - * first line and that fileage stays up to date. */ + /* Make sure that our edit window stays on the first line. */ openfile->edittop = fileptr; - } else - openfile->filebot = fileptr; openfile->fileage = fileptr; } else { assert(prevnode != NULL);