Commit 42227b5f authored by Jan Rybar's avatar Jan Rybar

Merge branch 'err-msgs-to-debug' into 'master'

Err msgs to debug

See merge request polkit/polkit!3
parents c747ce10 8c1bc8ab
......@@ -178,10 +178,10 @@ on_notify_authority_owner (GObject *object,
owner = polkit_authority_get_owner (server->authority);
if (owner == NULL)
{
g_printerr ("PolicyKit daemon disconnected from the bus.\n");
g_debug ("PolicyKit daemon disconnected from the bus.\n");
if (server->is_registered)
g_printerr ("We are no longer a registered authentication agent.\n");
g_debug ("We are no longer a registered authentication agent.\n");
server->is_registered = FALSE;
}
......@@ -192,17 +192,17 @@ on_notify_authority_owner (GObject *object,
{
GError *error;
g_printerr ("PolicyKit daemon reconnected to bus.\n");
g_printerr ("Attempting to re-register as an authentication agent.\n");
g_debug ("PolicyKit daemon reconnected to bus.\n");
g_debug ("Attempting to re-register as an authentication agent.\n");
error = NULL;
if (server_register (server, &error))
{
g_printerr ("We are now a registered authentication agent.\n");
g_debug ("We are now a registered authentication agent.\n");
}
else
{
g_printerr ("Failed to register as an authentication agent: %s\n", error->message);
g_debug ("Failed to register as an authentication agent: %s\n", error->message);
g_error_free (error);
}
}
......
......@@ -160,7 +160,8 @@ main (int argc, char *argv[])
authority = polkit_authority_get_sync (NULL /* GCancellable* */, &error);
if (authority == NULL)
{
g_printerr ("Error getting authority: %s (%s, %d)\n",
g_printerr ("Authorization not available. Check if polkit service is running or see debug message for more information.\n");
g_debug ("Error getting authority: %s (%s, %d)\n",
error->message, g_quark_to_string (error->domain), error->code);
g_error_free (error);
ret = 127;
......
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