From 6230706c43d86d2fcb776a8f568d4700db0ed462 Mon Sep 17 00:00:00 2001 From: Aaron Knister Date: Sun, 25 Feb 2018 18:11:56 -0500 Subject: [PATCH] be more explicit about default stanza naming convention --- perl-xCAT/xCAT/DBobjUtils.pm | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/perl-xCAT/xCAT/DBobjUtils.pm b/perl-xCAT/xCAT/DBobjUtils.pm index 9eb185374..fc9e9b0fd 100755 --- a/perl-xCAT/xCAT/DBobjUtils.pm +++ b/perl-xCAT/xCAT/DBobjUtils.pm @@ -1676,13 +1676,10 @@ sub readFileInput # could have different default stanzas for different object types - if ($objectname =~ /default/) { + if ($objectname =~ /^default-([^-]+)$/) { - ($junk1, $objtype) = split(/-/, $objectname); - - if ($objtype) { - $objectname = 'default'; - } + $objtype = $1; + $objectname = 'default'; next; }