[network-manager-openconnect] core: update for nm_warning/nm_info going away (bgo #645794)



commit 2e450950a6bb6b38f427f7891b5809cb6d250d17
Author: Christopher Aillon <caillon redhat com>
Date:   Tue Mar 29 17:02:25 2011 -0500

    core: update for nm_warning/nm_info going away (bgo #645794)

 src/nm-openconnect-service-openconnect-helper.c |   16 ++++++++--------
 src/nm-openconnect-service.c                    |   16 ++++++++--------
 2 files changed, 16 insertions(+), 16 deletions(-)
---
diff --git a/src/nm-openconnect-service-openconnect-helper.c b/src/nm-openconnect-service-openconnect-helper.c
index c195d46..01af370 100644
--- a/src/nm-openconnect-service-openconnect-helper.c
+++ b/src/nm-openconnect-service-openconnect-helper.c
@@ -48,7 +48,7 @@ helper_failed (DBusGConnection *connection, const char *reason)
 	DBusGProxy *proxy;
 	GError *err = NULL;
 
-	nm_warning ("nm-nopenconnect-service-openconnect-helper did not receive a valid %s from openconnect", reason);
+	g_warning ("nm-nopenconnect-service-openconnect-helper did not receive a valid %s from openconnect", reason);
 
 	proxy = dbus_g_proxy_new_for_name (connection,
 								NM_DBUS_SERVICE_OPENCONNECT,
@@ -61,7 +61,7 @@ helper_failed (DBusGConnection *connection, const char *reason)
 				    G_TYPE_INVALID);
 
 	if (err) {
-		nm_warning ("Could not send failure information: %s", err->message);
+		g_warning ("Could not send failure information: %s", err->message);
 		g_error_free (err);
 	}
 
@@ -88,7 +88,7 @@ send_ip4_config (DBusGConnection *connection, GHashTable *config)
 				    G_TYPE_INVALID);
 
 	if (err) {
-		nm_warning ("Could not send failure information: %s", err->message);
+		g_warning ("Could not send failure information: %s", err->message);
 		g_error_free (err);
 	}
 
@@ -230,7 +230,7 @@ get_routes (void)
 		snprintf (buf, BUFLEN, "CISCO_SPLIT_INC_%d_ADDR", i);
 		tmp = getenv (buf);
 		if (!tmp || inet_pton (AF_INET, tmp, &network) <= 0) {
-			nm_warning ("Ignoring invalid static route address '%s'", tmp ? tmp : "NULL");
+			g_warning ("Ignoring invalid static route address '%s'", tmp ? tmp : "NULL");
 			continue;
 		}
 
@@ -242,7 +242,7 @@ get_routes (void)
 			errno = 0;
 			tmp_prefix = strtol (tmp, NULL, 10);
 			if (errno || tmp_prefix <= 0 || tmp_prefix > 32) {
-				nm_warning ("Ignoring invalid static route prefix '%s'", tmp ? tmp : "NULL");
+				g_warning ("Ignoring invalid static route prefix '%s'", tmp ? tmp : "NULL");
 				continue;
 			}
 			prefix = (guint32) tmp_prefix;
@@ -252,7 +252,7 @@ get_routes (void)
 			snprintf (buf, BUFLEN, "CISCO_SPLIT_INC_%d_MASK", i);
 			tmp = getenv (buf);
 			if (!tmp || inet_pton (AF_INET, tmp, &netmask) <= 0) {
-				nm_warning ("Ignoring invalid static route netmask '%s'", tmp ? tmp : "NULL");
+				g_warning ("Ignoring invalid static route netmask '%s'", tmp ? tmp : "NULL");
 				continue;
 			}
 			prefix = nm_utils_ip4_netmask_to_prefix (netmask.s_addr);
@@ -310,7 +310,7 @@ main (int argc, char *argv[])
 
 	connection = dbus_g_bus_get (DBUS_BUS_SYSTEM, &err);
 	if (!connection) {
-		nm_warning ("Could not get the system bus: %s", err->message);
+		g_warning ("Could not get the system bus: %s", err->message);
 		exit (1);
 	}
 
@@ -392,7 +392,7 @@ main (int argc, char *argv[])
 		errno = 0;
 		mtu = strtol (tmp, NULL, 10);
 		if (errno || mtu < 0 || mtu > 20000) {
-			nm_warning ("Ignoring invalid tunnel MTU '%s'", tmp);
+			g_warning ("Ignoring invalid tunnel MTU '%s'", tmp);
 		} else {
 			val = uint_to_gvalue ((guint32) mtu);
 			g_hash_table_insert (config, NM_VPN_PLUGIN_IP4_CONFIG_MTU, val);
diff --git a/src/nm-openconnect-service.c b/src/nm-openconnect-service.c
index d8d96ec..b2f8e83 100644
--- a/src/nm-openconnect-service.c
+++ b/src/nm-openconnect-service.c
@@ -223,14 +223,14 @@ openconnect_watch_cb (GPid pid, gint status, gpointer user_data)
 	if (WIFEXITED (status)) {
 		error = WEXITSTATUS (status);
 		if (error != 0)
-			nm_warning ("openconnect exited with error code %d", error);
+			g_warning ("openconnect exited with error code %d", error);
 	}
 	else if (WIFSTOPPED (status))
-		nm_warning ("openconnect stopped unexpectedly with signal %d", WSTOPSIG (status));
+		g_warning ("openconnect stopped unexpectedly with signal %d", WSTOPSIG (status));
 	else if (WIFSIGNALED (status))
-		nm_warning ("openconnect died with signal %d", WTERMSIG (status));
+		g_warning ("openconnect died with signal %d", WTERMSIG (status));
 	else
-		nm_warning ("openconnect died from an unknown cause");
+		g_warning ("openconnect died from an unknown cause");
 
 	/* Reap child if needed. */
 	waitpid (priv->pid, NULL, WNOHANG);
@@ -351,16 +351,16 @@ nm_openconnect_start_openconnect_binary (NMOPENCONNECTPlugin *plugin,
 								   openconnect_drop_child_privs, NULL,
 								   &pid, &stdin_fd, NULL, NULL, error)) {
 		g_ptr_array_free (openconnect_argv, TRUE);
-		nm_warning ("openconnect failed to start.  error: '%s'", (*error)->message);
+		g_warning ("openconnect failed to start.  error: '%s'", (*error)->message);
 		return -1;
 	}
 	g_ptr_array_free (openconnect_argv, TRUE);
 
-	nm_info ("openconnect started with pid %d", pid);
+	g_message ("openconnect started with pid %d", pid);
 
 	if (write(stdin_fd, props_cookie, strlen(props_cookie)) != strlen(props_cookie) ||
 		write(stdin_fd, "\n", 1) != 1) {
-		nm_warning ("openconnect didn't eat the cookie we fed it");
+		g_warning ("openconnect didn't eat the cookie we fed it");
 		return -1;
 	}
 
@@ -459,7 +459,7 @@ real_disconnect (NMVPNPlugin   *plugin,
 		else
 			kill (priv->pid, SIGKILL);
 
-		nm_info ("Terminated openconnect daemon with PID %d.", priv->pid);
+		g_message ("Terminated openconnect daemon with PID %d.", priv->pid);
 		priv->pid = 0;
 	}
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]