Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
90137257
Commit
90137257
authored
Jan 30, 2015
by
Mike Hibler
Browse files
subosids() array has to have a "pid/osid" index as well as just "osid".
parent
79439d86
Changes
1
Hide whitespace changes
Inline
Side-by-side
tbsetup/ns2ir/parse-ns.in
View file @
90137257
...
...
@@ -699,7 +699,7 @@ sub GenDefsFile($)
}
print
TCL
"
# subOSIDs and parent OSIDs (default parent first element)
\n
";
$query_result
=
DBQueryFatal
("
select oi.osname,oi3.osname,
"
.
DBQueryFatal
("
select
oi.pid,
oi.osname,oi3.osname,
"
.
"
group_concat(oi2.osname separator '
\"
\"
')
"
.
"
from os_submap as osm
"
.
"
left join os_info as oi on osm.osid=oi.osid
"
.
...
...
@@ -714,13 +714,14 @@ sub GenDefsFile($)
"
where ov.def_parentosid is not NULL
"
.
"
group by oi.osname
");
while
(
my
(
$osname
,
$def_parentosid
,
$parent_osids
)
=
while
(
my
(
$
pid
,
$
osname
,
$def_parentosid
,
$parent_osids
)
=
$query_result
->
fetchrow_array
())
{
my
$parentlist
=
"
\"
$def_parentosid
\"
";
if
(
defined
(
$parent_osids
)
&&
$parent_osids
ne
'')
{
$parentlist
.=
"
\"
$parent_osids
\"
";
}
print
TCL
"
set subosids(
$osname
) [list
$parentlist
]
\n
";
print
TCL
"
set subosids(
$pid
/
$osname
)
\$
subosids(
$osname
)
\n
";
}
print
TCL
"
\n
";
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment