Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Bjørn Villa
qstream
Commits
6a0aef02
Commit
6a0aef02
authored
Jul 13, 2012
by
paalmm
Browse files
removed duplicate print_out if ==
parent
5f112496
Changes
1
Hide whitespace changes
Inline
Side-by-side
qstream
View file @
6a0aef02
...
...
@@ -173,7 +173,6 @@ $SIG{TERM} = sub { $uninterrupted=0; # return if $nkill++ < 1;
$
SIG
{
ALRM
}
=
sub
{
#
Writes
stats
to
file
if
option
XML
is
given
.
-
PMM
#
die
"No packets received"
if
$
n_packets
<
1
;
print
"alarmen går !
\n
"
;
$
uninterrupted
=
0
;
if
(! $endstream) { # Changed logic 20120706:1007 CDT
$endstream=1;
...
...
@@ -217,7 +216,7 @@ if ($opt_pcap || ($opt_tcp && !$opt_rtmp)){ # listen in parallell
eat_stream($id) if (!($opt_tcp || $opt_rtmp));
&rtmp_eat_stream($id,$opt_period, $opt_last,0,$opt_debug,$opt_swfurl,$opt_pageurl,$opt_flashversion) if $opt_rtmp;
#&eat_tcp($id,$opt_port) if $opt_tcp && !$opt_rtmp;
if (! ( $opt_list || $opt_sum)){
if (! ( $opt_list || $opt_sum
|| $opt_period
)){
&display_stats();
}
last if ! $uninterrupted;
...
...
@@ -687,8 +686,8 @@ sub eat_stream {
if ($opt_align){ # align to $opt_period
}
while ($uninterrupted && !($opt_packets && $n_packets > $opt_packets)){
#
while ($uninterrupted && !($opt_packets && $n_packets > $opt_packets)){
while ($uninterrupted && ! $endstream && !($opt_packets && $n_packets > $opt_packets)){
if ($select->can_read($timeout) && $mc->recv($packet, 1560)) {
my $timeout=$next_wait;
$n_packets++;
...
...
@@ -717,7 +716,7 @@ sub eat_stream {
print DUMP $packet;
}
last if ! $uninterrupted || $endstream;
#
$endstream = tv_interval($t0, $tc) >= $opt_last if $opt_last && !$endstream;
$endstream = tv_interval($t0, $tc) >= $opt_last if $opt_last && !$endstream;
} else { # assume that we got an interrupt
# die "Failed to receive packet: $!";
}
...
...
@@ -1585,7 +1584,7 @@ sub pkt_stats {
}
printf
"setup $f : %.3f
\n
"
,
$
setuptime
{$
f
}
if
$
opt_debug
;
#
print
"hei hei
\n
"
;
#
alarm
($
opt_last
)
if
$
opt_last
;
alarm
($
opt_last
)
if
$
opt_last
;
}
}
$
tend
{$
f
}
=
$
tc
;
...
...
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