Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=fw-control-center.git;a=commitdiff;h=f192face76f860eeb689bd850f755782ce21282c

commit f192face76f860eeb689bd850f755782ce21282c
Author: Priyank <[EMAIL PROTECTED]>
Date:   Fri Sep 21 01:14:06 2007 +0530

gnetconfig-interface: don't write a gateway line if the gateway entry is blank

diff --git a/gnetconfig/src/gnetconfig-interface.c 
b/gnetconfig/src/gnetconfig-interface.c
index f9626ba..2c654ed 100644
--- a/gnetconfig/src/gnetconfig-interface.c
+++ b/gnetconfig/src/gnetconfig-interface.c
@@ -1353,7 +1353,10 @@ cb_gn_save_interface_clicked (GtkButton *button, 
gpointer data)
interface->options->data = g_strdup_printf ("%s netmask %s",
ipaddr,
netmask);
-                       sprintf (interface->gateway, "default gw %s", gateway);
+                       if (strlen(gateway))
+                               sprintf (interface->gateway, "default gw %s", 
gateway);
+                       else
+                               *interface->gateway = 0;
type = GN_STATIC;

break;
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to