From c428cafb6323d1c9719643f4e79e23d4382d496a Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Sat, 6 Sep 2008 21:55:07 +0000 Subject: [PATCH] -Give errors on makedns on certain evidently frequent weird things being tried unintentionally git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@2081 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/bind.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xCAT-server/lib/xcat/plugins/bind.pm b/xCAT-server/lib/xcat/plugins/bind.pm index fcfc6c401..fdf5b5933 100755 --- a/xCAT-server/lib/xcat/plugins/bind.pm +++ b/xCAT-server/lib/xcat/plugins/bind.pm @@ -825,7 +825,11 @@ sub PARSEARGS { } $net =~ s/\.$//; + if (not $net) { + $callback->({error=>["Empty network found in networks table (i.e. ,,,,), This is almost certainly going to cause a problem..."],errorcode=>[1]}); + } if ($subnetmask eq "") { + $callback->({error=>["$net has no defined netmask in the networks table, the result will probably be wrong"],errorcode=>[1]}); foreach $tmp1 (&SUBNETS($net, $Defsubnetmask)) { &BUILDNET($tmp1); }