Fix bug in user prompt where line was not flushed on negative response
This commit is contained in:
parent
a73e131f10
commit
fed7e7850b
@ -624,9 +624,10 @@ FIO_openDstFile(FIO_prefs_t* const prefs,
|
|||||||
{ int ch = getchar();
|
{ int ch = getchar();
|
||||||
if ((ch!='Y') && (ch!='y')) {
|
if ((ch!='Y') && (ch!='y')) {
|
||||||
DISPLAY(" not overwritten \n");
|
DISPLAY(" not overwritten \n");
|
||||||
|
/* flush rest of input line */
|
||||||
|
while ((ch!=EOF) && (ch!='\n')) ch = getchar();
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
/* flush rest of input line */
|
|
||||||
while ((ch!=EOF) && (ch!='\n')) ch = getchar();
|
while ((ch!=EOF) && (ch!='\n')) ch = getchar();
|
||||||
} }
|
} }
|
||||||
/* need to unlink */
|
/* need to unlink */
|
||||||
|
Loading…
Reference in New Issue
Block a user