Merge pull request #191 from mgiacomoli/ask-fingerprint-flush-stdin

Dbclient: Flush stdin after fingerprint confirmation
This commit is contained in:
Matt Johnston
2022-10-25 23:47:45 +08:00
committed by GitHub

View File

@@ -229,6 +229,8 @@ static void ask_to_confirm(const unsigned char* keyblob, unsigned int keybloblen
fclose(tty);
} else {
response = getc(stdin);
/* flush stdin buffer */
while ((getchar()) != '\n');
}
if (response == 'y') {