Merge branch 'wip/nielsdg/no-g-message' into 'master'

Prefer g_info() over g_message()

Closes #40

See merge request GNOME/libsecret!48
This commit is contained in:
Daiki Ueno 2020-03-11 05:43:19 +00:00
commit 741867c361
3 changed files with 9 additions and 12 deletions

View File

@ -806,8 +806,7 @@ _secret_file_backend_check_portal_version (void)
0, -1, NULL, &error);
g_object_unref (connection);
if (!ret) {
g_message ("secret portal is not available: %s",
error->message);
g_info ("secret portal is not available: %s", error->message);
g_error_free (error);
return FALSE;
}
@ -817,8 +816,7 @@ _secret_file_backend_check_portal_version (void)
version = g_variant_get_uint32 (value);
g_variant_unref (value);
if (version != PORTAL_SECRET_VERSION) {
g_message ("secret portal version mismatch: %u != %u",
version, PORTAL_SECRET_VERSION);
g_info ("secret portal version mismatch: %u != %u", version, PORTAL_SECRET_VERSION);
return FALSE;
}

View File

@ -393,12 +393,12 @@ service_decode_aes_secret (SecretSession *session,
gsize pos;
if (n_param != 16) {
g_message ("received an encrypted secret structure with invalid parameter");
g_info ("received an encrypted secret structure with invalid parameter");
return NULL;
}
if (n_value == 0 || n_value % 16 != 0) {
g_message ("received an encrypted secret structure with bad secret length");
g_info ("received an encrypted secret structure with bad secret length");
return NULL;
}
@ -439,7 +439,7 @@ service_decode_aes_secret (SecretSession *session,
if (!pkcs7_unpad_bytes_in_place (padded, &n_padded)) {
egg_secure_clear (padded, n_padded);
egg_secure_free (padded);
g_message ("received an invalid or unencryptable secret");
g_info ("received an invalid or unencryptable secret");
return FALSE;
}
@ -457,7 +457,7 @@ service_decode_plain_secret (SecretSession *session,
const gchar *content_type)
{
if (n_param != 0) {
g_message ("received a plain secret structure with invalid parameter");
g_info ("received a plain secret structure with invalid parameter");
return NULL;
}
@ -485,8 +485,8 @@ _secret_session_decode_secret (SecretSession *session,
g_variant_get_child (encoded, 0, "o", &session_path);
if (session_path == NULL || !g_str_equal (session_path, session->path)) {
g_message ("received a secret encoded with wrong session: %s != %s",
session_path, session->path);
g_info ("received a secret encoded with wrong session: %s != %s",
session_path, session->path);
g_free (session_path);
return NULL;
}

View File

@ -125,8 +125,7 @@ _secret_util_strip_remote_error (GError **error)
remote = g_dbus_error_get_remote_error (*error);
if (remote) {
if (g_dbus_error_strip_remote_error (*error)) {
g_message ("Remote error from secret service: %s: %s",
remote, (*error)->message);
g_info ("Remote error from secret service: %s: %s", remote, (*error)->message);
}
g_free (remote);
}