Skip to content
GitLab
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
16e340f1
Commit
16e340f1
authored
Jun 02, 2004
by
Robert Ricci
Browse files
Sort the LANs and nodes before we put them into the topo file, so
that two identical topologies always produce identical topofiles.
parent
195aea10
Changes
1
Hide whitespace changes
Inline
Side-by-side
tbsetup/gentopofile.in
View file @
16e340f1
...
...
@@ -155,7 +155,7 @@ while (my ($vname,$member,$mask,$cost) = $query_result->fetchrow_array) {
#
print
$OUT
"
# nodes: vname,links
\n
";
foreach
my
$node
(
keys
(
%nodes
))
{
foreach
my
$node
(
sort
keys
(
%nodes
))
{
print
$OUT
"
$node
,
";
print
$OUT
join
("
",
values
(
%
{
$nodes
{
$node
}
}));
print
$OUT
"
\n
";
...
...
@@ -166,7 +166,7 @@ foreach my $node (keys(%nodes)) {
#
print
$OUT
"
# lans: vname,mask,cost
\n
";
foreach
my
$lan
(
keys
(
%lans
))
{
foreach
my
$lan
(
sort
keys
(
%lans
))
{
my
$cost
=
$lans
{
$lan
}
->
{"
cost
"};
my
$mask
=
$lans
{
$lan
}
->
{"
mask
"};
print
$OUT
"
$lan
,
$mask
,
$cost
\n
";
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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