tweaks: fix compilation with --enable-tiny again

master
Benno Schulenberg 2016-08-30 09:11:33 +02:00
parent 514cd9a099
commit c11c688420
1 changed files with 18 additions and 12 deletions

View File

@ -652,7 +652,7 @@ int do_prompt(bool allow_tabs,
void (*refresh_func)(void), const char *msg, ...)
{
va_list ap;
int retval = KEY_WINCH;
int retval;
functionptrtype func = NULL;
#ifndef DISABLE_TABCOMP
bool listed = FALSE;
@ -664,7 +664,9 @@ int do_prompt(bool allow_tabs,
answer = mallocstrcpy(answer, curranswer);
while (retval == KEY_WINCH) {
#ifndef NANO_TINY
redo_theprompt:
#endif
prompt = charalloc((COLS * mb_cur_max()) + 1);
va_start(ap, msg);
vsnprintf(prompt, COLS * mb_cur_max(), msg, ap);
@ -683,7 +685,11 @@ int do_prompt(bool allow_tabs,
free(prompt);
prompt = NULL;
}
#ifndef NANO_TINY
if (retval == KEY_WINCH)
goto redo_theprompt;
#endif
/* If we're done with this prompt, restore the x position to what
* it was at a possible previous prompt. */