Commit 9acacefa authored by Bastien Nocera's avatar Bastien Nocera

pam: Fix "format-nonliteral" warning

In file included from tests/enroll.c:29:0:
pam/fingerprint-strings.h: In function ‘finger_str_to_msg’:
pam/fingerprint-strings.h:99:6: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
      return g_strdup_printf (TR (fingers[i].place_str_specific), driver_name);
      ^~~~~~
pam/fingerprint-strings.h:104:6: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
      return g_strdup_printf (TR (fingers[i].swipe_str_specific), driver_name);
      ^~~~~~
parent ac1a99ad
......@@ -85,6 +85,9 @@ struct {
{ NULL, NULL, NULL, NULL, NULL }
};
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wformat-nonliteral"
static char *finger_str_to_msg(const char *finger_name, const char *driver_name, gboolean is_swipe)
{
int i;
......@@ -111,6 +114,8 @@ static char *finger_str_to_msg(const char *finger_name, const char *driver_name,
return NULL;
}
#pragma GCC diagnostic pop
/* Cases not handled:
* verify-no-match
* verify-match
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment