From 7279ea1317767353d5d32e387e6b5f741cfe1f0b Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Oct 2016 12:30:41 +0000 Subject: [PATCH] client: don't do g_criticals Also, be a bit more careful about the layers of errors. Just don't do this: (process:236): nmcli-CRITICAL **: Error: Could not create NMClient object: Permissions request failed: Authorization check failed: The name org.freedesktop.PolicyKit1 was not provided by any .service files. --- clients/cli/nmcli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clients/cli/nmcli.c b/clients/cli/nmcli.c index 890dc0d062..6e27c3d668 100644 --- a/clients/cli/nmcli.c +++ b/clients/cli/nmcli.c @@ -520,7 +520,7 @@ nmc_get_client (NmCli *nmc) if (!nmc->client) { nmc->client = nm_client_new (NULL, &error); if (!nmc->client) { - g_critical (_("Error: Could not create NMClient object: %s."), error->message); + g_printerr ("%s\n", error->message); g_clear_error (&error); exit (NMC_RESULT_ERROR_UNKNOWN); }