mirror of
https://gitlab.freedesktop.org/libfprint/fprintd.git
synced 2025-12-25 02:30:09 +01:00
pam: Always return translated string from helper
This means that the different functions in the header match as all functions will return the translted string instead of only one of them.
This commit is contained in:
parent
2fd86624e5
commit
c42e627ddd
2 changed files with 11 additions and 11 deletions
|
|
@ -153,16 +153,16 @@ GNUC_UNUSED static const char *verify_result_str_to_msg(const char *result, bool
|
|||
|
||||
if (strcmp (result, "verify-retry-scan") == 0) {
|
||||
if (is_swipe == false)
|
||||
return N_("Place your finger on the reader again");
|
||||
return TR (N_("Place your finger on the reader again"));
|
||||
else
|
||||
return N_("Swipe your finger again");
|
||||
return TR (N_("Swipe your finger again"));
|
||||
}
|
||||
if (strcmp (result, "verify-swipe-too-short") == 0)
|
||||
return N_("Swipe was too short, try again");
|
||||
return TR (N_("Swipe was too short, try again"));
|
||||
if (strcmp (result, "verify-finger-not-centered") == 0)
|
||||
return N_("Your finger was not centered, try swiping your finger again");
|
||||
return TR (N_("Your finger was not centered, try swiping your finger again"));
|
||||
if (strcmp (result, "verify-remove-and-retry") == 0)
|
||||
return N_("Remove your finger, and try swiping your finger again");
|
||||
return TR (N_("Remove your finger, and try swiping your finger again"));
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
|
@ -179,16 +179,16 @@ GNUC_UNUSED static const char *enroll_result_str_to_msg(const char *result, bool
|
|||
|
||||
if (strcmp (result, "enroll-retry-scan") == 0 || strcmp (result, "enroll-stage-passed") == 0) {
|
||||
if (is_swipe == false)
|
||||
return N_("Place your finger on the reader again");
|
||||
return TR (N_("Place your finger on the reader again"));
|
||||
else
|
||||
return N_("Swipe your finger again");
|
||||
return TR (N_("Swipe your finger again"));
|
||||
}
|
||||
if (strcmp (result, "enroll-swipe-too-short") == 0)
|
||||
return N_("Swipe was too short, try again");
|
||||
return TR (N_("Swipe was too short, try again"));
|
||||
if (strcmp (result, "enroll-finger-not-centered") == 0)
|
||||
return N_("Your finger was not centered, try swiping your finger again");
|
||||
return TR (N_("Your finger was not centered, try swiping your finger again"));
|
||||
if (strcmp (result, "enroll-remove-and-retry") == 0)
|
||||
return N_("Remove your finger, and try swiping your finger again");
|
||||
return TR (N_("Remove your finger, and try swiping your finger again"));
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -201,7 +201,7 @@ verify_result (sd_bus_message *m,
|
|||
return 0;
|
||||
}
|
||||
|
||||
msg = _(verify_result_str_to_msg (result, data->is_swipe));
|
||||
msg = verify_result_str_to_msg (result, data->is_swipe);
|
||||
send_err_msg (data->pamh, msg);
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue