diff options
author | Chen Hanxiao <chenhanxiao@cn.fujitsu.com> | 2014-06-11 09:51:48 +0800 |
---|---|---|
committer | Chen Hanxiao <chenhanxiao@cn.fujitsu.com> | 2014-06-11 09:52:07 +0800 |
commit | 17a11672b142028f6e15b80f3a30b3069792d37f (patch) | |
tree | 466d2c846fe392bc7fa17b87bdb11ef95e1d4045 /virtManager/createnet.py | |
parent | d3d76beb5b558f0f7115d2d56a9377f3746eb146 (diff) | |
download | virt-manager-17a11672b142028f6e15b80f3a30b3069792d37f.tar.gz |
createnet: enable specify /29 subnet
https://bugzilla.redhat.com/show_bug.cgi?id=1106913
Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com>
Diffstat (limited to 'virtManager/createnet.py')
-rw-r--r-- | virtManager/createnet.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/virtManager/createnet.py b/virtManager/createnet.py index e9993929..4731d2ee 100644 --- a/virtManager/createnet.py +++ b/virtManager/createnet.py @@ -265,9 +265,9 @@ class vmmCreateNetwork(vmmGObjectUI): return self.err.val_err(_("Invalid Network Address"), _("The network must be an IPv4 address")) - if ip.numhosts < 16: + if ip.numhosts < 8: return self.err.val_err(_("Invalid Network Address"), - _("The network must address at least 16 addresses.")) + _("The network must address at least 8 addresses.")) if ip.prefixlen < 15: return self.err.val_err(_("Invalid Network Address"), @@ -563,7 +563,7 @@ class vmmCreateNetwork(vmmGObjectUI): src.modify_bg(Gtk.StateType.NORMAL, _red) return - valid_ip = (ip.numhosts >= 16 and ip.is_private) + valid_ip = (ip.numhosts >= 8 and ip.is_private) gateway = (ip.prefixlen != 32 and str(ip.network + 1) or "") info = (ip.is_private and _("Private") or _("Other/Public")) start = int(ip.numhosts / 2) |