ref: c372a2eb4bc59a0c7240b1055fe063ec781d5261
parent: 6d61f3f10374b4c58f9ef76e5bdf76da15dcd98e
author: Timothy B. Terriberry <[email protected]>
date: Mon Oct 22 16:42:15 EDT 2012
One small addendum to 7c52622f. This case can basically only get hit if there's another stream multiplexed in with ours, but this avoids re-scanning the same data multiple times when it happens.
--- a/src/opusfile.c
+++ b/src/opusfile.c
@@ -2173,6 +2173,9 @@
if(OP_UNLIKELY(ret<0))return ret;
/*Bump up the chunk size.*/
chunk_size=OP_MIN(2*chunk_size,OP_CHUNK_SIZE_MAX);
+ /*If we did find a page from another stream or without a timestamp,
+ don't read past it.*/
+ boundary=next_boundary;
}
}
else{