|
@@ -1,4 +1,4 @@
|
|
|
-// Ogg Vorbis audio decoder - v1.13 - public domain
|
|
|
+// Ogg Vorbis audio decoder - v1.13b - public domain
|
|
|
// http://nothings.org/stb_vorbis/
|
|
|
//
|
|
|
// Original version written by Sean Barrett in 2007.
|
|
@@ -3398,7 +3398,7 @@ static int vorbis_decode_packet_rest(vorb *f, int *len, Mode *m, int left_start,
|
|
|
if (f->last_seg_which == f->end_seg_with_known_loc) {
|
|
|
// if we have a valid current loc, and this is final:
|
|
|
if (f->current_loc_valid && (f->page_flag & PAGEFLAG_last_page)) {
|
|
|
- uint32 current_end = f->known_loc_for_packet - (n-right_end);
|
|
|
+ uint32 current_end = f->known_loc_for_packet;
|
|
|
// then let's infer the size of the (probably) short final frame
|
|
|
if (current_end < f->current_loc + (right_end-left_start)) {
|
|
|
if (current_end < f->current_loc) {
|
|
@@ -3407,7 +3407,7 @@ static int vorbis_decode_packet_rest(vorb *f, int *len, Mode *m, int left_start,
|
|
|
} else {
|
|
|
*len = current_end - f->current_loc;
|
|
|
}
|
|
|
- *len += left_start;
|
|
|
+ *len += left_start; // this doesn't seem right, but has no ill effect on my test files
|
|
|
if (*len > right_end) *len = right_end; // this should never happen
|
|
|
f->current_loc += *len;
|
|
|
return TRUE;
|