patch to applet-dialogs



If the default gateway is not explicitly set, then it currently is displayed as "0.0.0.0" in the "Connection Information" box. This patch disables the display of the "Default Route" tag if it isn't set.

--- src/applet-dialogs.c.orig	2008-06-02 08:28:05.000000000 -0400
+++ src/applet-dialogs.c	2008-06-03 11:47:59.000000000 -0400
@@ -367,13 +367,15 @@
 	row++;
 
 	/* Gateway */
-	gtk_table_attach_defaults (table,
+	if ( def_addr->gateway != 0 ) {
+		gtk_table_attach_defaults (table,
 							   create_info_label (_("Default Route:")),
 							   0, 1, row, row + 1);
-	gtk_table_attach_defaults (table,
+		gtk_table_attach_defaults (table,
 							   create_info_label (ip4_address_as_string (def_addr->gateway)),
 							   1, 2, row, row + 1);
-	row++;
+		row++;
+	}
 
 	/* DNS */
 	dns = nm_ip4_config_get_nameservers (ip4_config);



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