diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2009-10-26 01:04:40 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2009-10-26 01:04:40 +0000 |
commit | 095d2bd5b287362b3faf0026b479227236399be1 (patch) | |
tree | 0080662085fc3e947f4fa71090ad1d005efe6f59 /libs/ardour/audiosource.cc | |
parent | 57f66fc1d034466b8bd0232e4bfd4b8f9bf02da2 (diff) |
fix for peak data reading (carl h, #2388)
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@5920 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/audiosource.cc')
-rw-r--r-- | libs/ardour/audiosource.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/ardour/audiosource.cc b/libs/ardour/audiosource.cc index 36a667d109..3d6e804a60 100644 --- a/libs/ardour/audiosource.cc +++ b/libs/ardour/audiosource.cc @@ -374,7 +374,7 @@ AudioSource::read_peaks_with_fpp (PeakData *peaks, nframes_t npeaks, nframes_t s } if (zero_fill) { - memset (&peaks[npeaks], 0, sizeof (PeakData) * zero_fill); + memset (peaks + npeaks - zero_fill, 0, sizeof (PeakData) * zero_fill); } return 0; @@ -485,7 +485,7 @@ AudioSource::read_peaks_with_fpp (PeakData *peaks, nframes_t npeaks, nframes_t s } if (zero_fill) { - memset (&peaks[npeaks], 0, sizeof (PeakData) * zero_fill); + memset (peaks + npeaks - zero_fill, 0, sizeof (PeakData) * zero_fill); } ret = 0; @@ -562,7 +562,7 @@ AudioSource::read_peaks_with_fpp (PeakData *peaks, nframes_t npeaks, nframes_t s } if (zero_fill) { - memset (&peaks[npeaks], 0, sizeof (PeakData) * zero_fill); + memset (peaks + npeaks - zero_fill, 0, sizeof (PeakData) * zero_fill); } ret = 0; |