Chunk size too big

JDK Bug System | Webbug Group | 2 years ago
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    FULL PRODUCT VERSION : java version "1.8.0_45" Java(TM) SE Runtime Environment (build 1.8.0_45-b14) Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode) ADDITIONAL OS VERSION INFORMATION : Linux 3.13.0-61-generic #100-Ubuntu SMP Wed Jul 29 11:21:34 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux A DESCRIPTION OF THE PROBLEM : Trying to read Wav-Files greater than 2 GiB results in a RIFFInvalidDataException("Chunk size too big") asking the AudioSystem to read it. This change introduced it: But this exception just masks the underlying problem, that the readers behind are not able to read from such big streams. 1.7.0_80 does create the stream, but is unable to read from them. As a WAVE-File can be up to 4 GiB in size it should be possible to work with files greater than the current possible 2 GiB. STEPS TO FOLLOW TO REPRODUCE THE PROBLEM : 1. Create a 3 GiB wav file: dd if=/dev/zero of=silence.raw bs=1M count=3000 sox -r 16k -e signed -b 8 -c 1 silence.raw silence.wav 2. Compile the javac 3. Run the Code. java Sound /tmp/silence.wav EXPECTED VERSUS ACTUAL BEHAVIOR : EXPECTED - Creates an InputStream to work with the Wav-File, where i can read the complete stream. Note: Using 1.7.0_80 i can create the stream but reading always results in 0 bytes read. ACTUAL - java Sound /tmp/silence.wav Exception in thread "main" Chunk size too big at<init>( at at at at at javax.sound.sampled.AudioSystem.getAudioInputStream( at Sound.main( REPRODUCIBILITY : This bug can be reproduced always. ---------- BEGIN SOURCE ---------- import; import javax.sound.sampled.AudioSystem; public class Sound { public static void main(String[] args) throws Exception { AudioSystem.getAudioInputStream(new File(args[0])); } } ---------- END SOURCE ----------

    JDK Bug System | 2 years ago | Webbug Group Chunk size too big

    Root Cause Analysis


      Chunk size too big

    2. Java RT
      6. javax.sound.sampled.AudioSystem.getAudioInputStream(
      6 frames
    3. Unknown
      1. Sound.main(
      1 frame