limit data read to data chunk in wavread.m
author |
John W. Eaton <jwe@octave.org> |
date |
Fri, 08 Feb 2008 03:43:48 -0500 |
parents |
cb8d75cedc93 |
children |
dfcaf7ed48e3 |
files |
scripts/ChangeLog scripts/audio/wavread.m |
diffstat |
2 files changed, 5 insertions(+), 1 deletions(-)
[+]
|
line diff
--- a/scripts/ChangeLog
+++ b/scripts/ChangeLog
@@ -1,3 +1,7 @@
+2008-02-08 Julien Pommier <pommier@pianoteq.com>
+
+ * audio/wavread.m: Limit data read to end of data chunk.
+
2008-02-01 Dave Goel <deego3@gmail.com>
* signal/arch_rnd.m: Correctly index E and Y vectors.
--- a/scripts/audio/wavread.m
+++ b/scripts/audio/wavread.m
@@ -151,7 +151,7 @@
## parse arguments
if (nargin == 1)
- length = inf;
+ length = 8 * ck_size / bits_per_sample;
else
if (size (param, 2) == 1)
## number of samples is given