From 9317afc8bb7eec656444fc2eecfcd1ea3bfdda82 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Mar 15 2017 16:45:15 +0000 Subject: Fix errors with -Werror=format-security Recent versions of the Fedora build system treat format-security warnings as errors, resulting in failure to build. This patch ensures that appropriate format strings are present. Signed-off-by: Stephen Gallagher --- diff --git a/modules/files.c b/modules/files.c index 4ef0a57..6a7787e 100644 --- a/modules/files.c +++ b/modules/files.c @@ -534,7 +534,7 @@ parse_field(const struct format_specifier *format, GValue *value, string, &err); if (ret == FALSE) { g_assert(err != NULL); - g_warning(lu_strerror(err)); + g_warning("%s", lu_strerror(err)); lu_error_free(&err); } return ret; diff --git a/modules/ldap.c b/modules/ldap.c index ad10f73..02e9eb6 100644 --- a/modules/ldap.c +++ b/modules/ldap.c @@ -672,7 +672,7 @@ lu_ldap_lookup(struct lu_module *module, (&value, attr, val, &error); if (ok == FALSE) { g_assert(error != NULL); - g_warning(lu_strerror(error)); + g_warning("%s", lu_strerror(error)); lu_error_free(&error); } else { lu_ent_add_current(ent, attr,