Commit 65838a3b authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Add sanity check to make sure the imq device actually exists, since

the number is fixed and small.
parent 0eb8b6e8
......@@ -313,7 +313,9 @@ sub LinkDelaySetup()
$iface =~ /\D+(\d+)/;
my $imqnum = $1;
if ($type eq "duplex") {
if (! -e "/sys/class/net/imq${imqnum}") {
die("No such IMQ device: imq${imqnum}");
print DEL "$TC qdisc add dev imq${imqnum} handle $pipeno ";
print DEL "root plr $rplr\n";
Supports Markdown
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