_initial_pcmoffset uses error codes from vorbis_packet_blocksize in arithmetics
While working on #2140 (closed), I realized that the function _initial_pcmoffset
doesn't handle negative values (error codes) returned by vorbis_packet_blocksize
properly. It simply uses the returned value in an arithmetic expression, regardless the sign - which leads to an incorrect result. In change, the functions ov_raw_seek
and ov_pcm_seek
seem to skip the current packet, if vorbis_packet_blocksize
returns a negative value.
In the comments of #2140 (closed), tterribe suggested a fix that I'm attaching as patch, but couldn't test yet.