Mailing List Archive

Remove unused netmask, network etc. These were used when we called ifconfig to
# HG changeset patch
# User emellor@leeni.uk.xensource.com
# Node ID b4dfb49332d2935860ee8ddeebdfffcaef5e800b
# Parent bdcb115c667a12a5514517456639142c1273b0f1
Remove unused netmask,network etc. These were used when we called ifconfig to
set up the networking, but now that we use ip directly, we don't need them, and
they were in any case broken when the ip address was specified without a suffix.

This work is by James Dykman <dykman@us.ibm.com>.

Signed-off-by: Ewan Mellor <ewan@xensource.com>

diff -r bdcb115c667a -r b4dfb49332d2 tools/examples/vif-nat
--- a/tools/examples/vif-nat Sat Dec 10 23:20:08 2005
+++ b/tools/examples/vif-nat Mon Dec 12 11:15:29 2005
@@ -81,17 +81,6 @@

# Split the given IP/bits pair.
vif_ip=`echo ${ip} | awk -F/ '{print $1}'`
-bits=`echo ${ip} | awk -F/ '{print $2}'`
-
-# Convert $bits and $vif_ip to integers, mask appropriately to get a network
-# address, and convert them both to dotted quads.
-
-intmask=$(( (0xFFFFFFFF << (32 - $bits)) & 0xFFFFFFFF ))
-vif_int=$(( $(echo "((($vif_ip" | sed -e 's#\.#)\*256\+#g') ))
-
-netmask=$(dotted_quad $intmask)
-network=$(dotted_quad $(( $vif_int & $intmask )) )
-

hostname=$(xenstore_read "$XENBUS_PATH/domain" | tr -- '_.:/+' '-----')
if [ "$vifid" != "1" ]

_______________________________________________
Xen-changelog mailing list
Xen-changelog@lists.xensource.com
http://lists.xensource.com/xen-changelog