From 908805a2e88dd9513f8284a582a82f9445ce0dcf Mon Sep 17 00:00:00 2001 From: Chris Allegretta Date: Mon, 4 Dec 2000 04:42:56 +0000 Subject: [PATCH] Rocco's edit_add off by one fix git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@380 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- ChangeLog | 3 +++ winio.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index defa469e..7b70192d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,9 @@ CVS code - - Added O_EXCL to open call if tmp is set, more security which hopefully fixes any remaining security issues. - Added tmp check to TMP_OPT section (how apropriate). +- winio.c: + edit_add() + - Off by one display error (fix by Rocco Corsi). nano 0.9.22 - 12/02/2000 - General diff --git a/winio.c b/winio.c index 5103ff6c..2925cd74 100644 --- a/winio.c +++ b/winio.c @@ -761,7 +761,7 @@ void edit_add(filestruct * fileptr, int yval, int start, int virt_cur_x, #endif /* Just paint the string (no mark on this line) */ mvwaddnstr(edit, yval, 0, &fileptr->data[start], - get_page_end_virtual(this_page) - start); + get_page_end_virtual(this_page) - start + 1); } /*