private boolean nextFrameInfo ( ) throws IOException { while ( true ) { int size = 0 ; do { final int mySize = in . read ( readNumberBuff . array ( ) , size , LZ4FrameOutputStream . INTEGER_BYTES - size ) ; if ( mySize < 0 ) { return false ; } size += mySize ; } while ( size < LZ4FrameOutputStream . INTEGER_BYTES ) ; final int magic = readNumberBuff . getInt ( 0 ) ; if ( magic == LZ4FrameOutputStream . MAGIC ) { readHeader ( ) ; return true ; } else if ( ( magic >>> 4 ) == ( MAGIC_SKIPPABLE_BASE >>> 4 ) ) { skippableFrame ( ) ; } else { throw new IOException ( NOT_SUPPORTED ) ; } } }
Try and load in the next valid frame info . This will skip over skippable frames .