nano

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

commit 5487551ce969b88eb47e90226865a979763d2693
parent 763bf2ed260f18b274eaacc165242e8f9c71c5ee
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Sun, 26 Nov 2017 09:19:25 +0100

history: save the positions file also when a record was deleted

When a file is closed with the cursor on line 1, column 1, this
position is not recorded in file-positions history file -- if a
record for the file existed, it is deleted.  In the latter case
the history file needs to be saved, so that other instances of
nano will know about the deletion.

This fixes https://savannah.gnu.org/bugs/?52505.

Diffstat:
Msrc/history.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/src/history.c b/src/history.c @@ -548,6 +548,7 @@ void update_poshistory(char *filename, ssize_t lineno, ssize_t xpos) posprev->next = posptr->next; free(posptr->filename); free(posptr); + save_poshistory(); } free(fullpath); return;