mirror of
https://github.com/dkogan/feedgnuplot.git
synced 2025-09-23 23:18:08 +08:00
fixed broken plotting when a realtime plot has some curves run out of data
This commit is contained in:
@@ -556,7 +556,10 @@ sub pruneOldData
|
||||
if( @$xy > 1 )
|
||||
{
|
||||
my $firstInWindow = first_index {$_->[0] >= $oldestx} @{$xy}[1..$#$xy];
|
||||
splice( @$xy, 1, $firstInWindow ) unless $firstInWindow == -1;
|
||||
if($firstInWindow == -1)
|
||||
{ splice( @$xy, 1); }
|
||||
else
|
||||
{ splice( @$xy, 1, $firstInWindow ); }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user