memory: avoid a leak when toggling from Search to Goto

This fixes https://savannah.gnu.org/bugs/?53088.
master
Benno Schulenberg 2018-02-07 19:27:50 +01:00
parent 204e1b8353
commit 9ceeabda38
1 changed files with 2 additions and 1 deletions

View File

@ -615,7 +615,8 @@ int do_prompt(bool allow_tabs, bool allow_files,
bottombars(menu);
answer = mallocstrcpy(answer, curranswer);
if (answer != curranswer)
answer = mallocstrcpy(answer, curranswer);
#ifndef NANO_TINY
redo_theprompt: