don't call usleep when the delays are zero
This commit is contained in:
parent
a3412a0b81
commit
942590a840
1 changed files with 2 additions and 2 deletions
|
@ -127,8 +127,8 @@ while(1) {
|
|||
my $i = 1;
|
||||
while(read(FILE, $c, 1)) {
|
||||
$i++;
|
||||
usleep($first_delay) if ( $s == 0 );
|
||||
usleep($second_delay) if ( $s == 1 );
|
||||
usleep($first_delay) if ( $s == 0 ) && ($first_delay != 0);
|
||||
usleep($second_delay) if ( $s == 1 ) && ($second_delay != 0);
|
||||
$ob->write($c);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue