examples: Continue verification when return is pressed

The message says [Y/n], but will not do Y by default. Fix this.
This commit is contained in:
Benjamin Berg 2020-01-02 18:43:59 +01:00
parent dcc7e6de90
commit 516c1593bb

View file

@ -92,7 +92,7 @@ on_verify_completed (FpDevice *dev, GAsyncResult *res, void *user_data)
g_print ("Verify again? [Y/n]? ");
if (fgets (buffer, sizeof (buffer), stdin) &&
(buffer[0] == 'Y' || buffer[0] == 'y'))
(buffer[0] == 'Y' || buffer[0] == 'y' || buffer[0] == '\n'))
{
start_verification (dev, verify_data);
return;