From c8b872ae41e8fb37d76d1094ccb155038421255b Mon Sep 17 00:00:00 2001 From: Jonathan Moore Liles Date: Thu, 17 Apr 2008 10:45:36 -0500 Subject: [PATCH] Don't attempt to draw more peaks than were actually read! --- Timeline/Waveform.C | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Timeline/Waveform.C b/Timeline/Waveform.C index eef0565..1b0f439 100644 --- a/Timeline/Waveform.C +++ b/Timeline/Waveform.C @@ -57,6 +57,8 @@ Waveform::draw ( int X, int Y, int W, int H, const int halfheight = H / 2; const int mid = Y + halfheight; + W = min( peaks, W ); + if ( Waveform::fill ) { j = start;