Commit 9fd70424 authored by Mac Newbold's avatar Mac Newbold
Browse files

Fixed use of variables that aren't always defined.

parent 5c9a6444
......@@ -126,12 +126,15 @@ foreach (split("\n",$raw)) {
push(@$nodes_tmp,$_);
}
$links_tmp = [];
foreach (split(" ",$links_raw)) {
if (defined $links_raw) {
foreach (split(" ",$links_raw)) {
push(@$links_tmp,$_);
}
}
$delay =~ s/[mM][sS]$//;
$bw =~ s/[mM][bB]$//;
printdb "lans{$lan} = [$nodes_raw,$bw,$delay,$loss,$links_raw]\n";
printdb "lans{$lan} = [$nodes_raw,$bw,$delay,$loss".
(defined $links_raw ? ",$links_raw" : "")."]\n";
$lans{$lan} = [$nodes_tmp,$bw,$delay,$loss,$links_tmp];
}
......
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