memory: prevent a leak when copying the leading quoting to the next line

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

Bug existed since version 4.4, commit 8fce33af from two years ago,
since this automatic copying of the quoting part was introduced.
This commit is contained in:
Benno Schulenberg 2021-05-14 09:53:28 +02:00
parent 6472a6b828
commit f23e98dd3a

View File

@ -1333,6 +1333,7 @@ bool do_wrap(void)
openfile->current_x += lead_len;
#ifndef NANO_TINY
free(openfile->undotop->strdata);
update_undo(ENTER);
#endif
if (autowhite)