fix bad check causing mknb to run even with /install mounted

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@3213 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
lissav 2009-04-17 15:04:43 +00:00
parent 14810024f1
commit 801f5bbf2e

View File

@ -899,17 +899,18 @@ sub setup_TFTP
{
# read sharedtftp attribute from site table, if exist
my @sharedtftp = xCAT::Utils->get_site_attribute("sharedtftp");
if (exists($sharedtftp[0]))
my $stab = xCAT::Table->new('site');
my $sharedtftp = $stab->getAttribs({key=>'sharedtftp'},'value');
if ($sharedtftp)
{
$mountdirectory = $sharedtftp[0];
$mountdirectory = $sharedtftp->{value};
$mountdirectory =~ tr/a-z/A-Z/; # convert to upper
}
$stab->close;
# read tftpdir directory from database
my $tftpdir = "/tftpboot"; # default
my @tftpdir1 = xCAT::Utils->get_site_attribute("tftpdir");
if (exists($tftpdir1[0]))
if (defined($tftpdir1[0]))
{
$tftpdir = $tftpdir1[0];
}