Commit 72e9342d authored by Leigh Stoller's avatar Leigh Stoller

Bug fix to SetRunsOnParent().

parent 9047e21a
......@@ -629,12 +629,10 @@ sub RunsOnParent($$)
{
my ($self,$parent) = @_;
my ($osid,$osname) = ($self->osid(),$self->osname());
my $def_parentosid = $self->def_parentosid();
my ($osid,$osname) = ($self->osid(),$self->osname());
my $def_parentosid = $self->def_parentosid();
my ($posid,$posname) = ($parent->osid(),$parent->osname());
return 0
if (!$self->IsSubOS());
......@@ -658,19 +656,14 @@ sub SetRunsOnParent($$)
{
my ($self,$parent) = @_;
my ($osid,$osname) = ($self->osid(),$self->osname());
my $def_parentosid = $self->def_parentosid();
my ($posid,$posname) = ($parent->osid(),$parent->osname());
my $osid = $self->osid();
my $posid = $parent->osid();
return 0
if (!$self->IsSubOS());
return 1
if ($posid == $def_parentosid);
DBQueryWarn("replace into os_submap set ".
" osid=$osid and parent_osid=$posid")
" osid=$osid,parent_osid=$posid")
or return -1;
return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment