File: compressed-wav-files.patch

package info (click to toggle)
normalize-audio 0.7.7-21
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,032 kB
  • sloc: sh: 9,255; ansic: 8,286; perl: 635; makefile: 139; sed: 16
file content (17 lines) | stat: -rw-r--r-- 767 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
Author: Stefan Fritsch <sf@sfritsch.de>
Description: afGetVirtualFrameSize() needs to be used instead of afGetFrameSize(),
otherwise the allocated buffer size is too small for compressed
WAV files (see #558399).
--- a/src/adjust.c
+++ b/src/adjust.c
@@ -277,8 +277,8 @@
 
   /* set up buffer to hold 1/100 of a second worth of frames */
   frames_in_buf = samp_rate / 100;
-  src_framesz = afGetFrameSize(fhin, AF_DEFAULT_TRACK, 1);
-  dst_framesz = afGetFrameSize(fhout, AF_DEFAULT_TRACK, 1);
+  src_framesz = afGetVirtualFrameSize(fhin, AF_DEFAULT_TRACK, 1);
+  dst_framesz = afGetVirtualFrameSize(fhout, AF_DEFAULT_TRACK, 1);
   src_buf = (unsigned char *)xmalloc(frames_in_buf * src_framesz);
   dst_buf = (unsigned char *)xmalloc(frames_in_buf * dst_framesz);