don't use asserts in these tight spots

svn-id: r9420
This commit is contained in:
Max Horn 2003-08-02 17:27:17 +00:00
parent 4cc8c70f25
commit cc8465aa71

View File

@ -58,7 +58,7 @@ public:
assert(len % 2 == 0); assert(len % 2 == 0);
} }
int16 read() { int16 read() {
assert(_ptr < _end); //assert(_ptr < _end);
int16 val = readSample<is16Bit, isUnsigned>(_ptr); int16 val = readSample<is16Bit, isUnsigned>(_ptr);
_ptr += (is16Bit ? 2 : 1); _ptr += (is16Bit ? 2 : 1);
if (_loopPtr && _ptr == _end) { if (_loopPtr && _ptr == _end) {
@ -114,7 +114,7 @@ WrappedMemoryStream<stereo, is16Bit, isUnsigned>::WrappedMemoryStream(uint buffe
template<bool stereo, bool is16Bit, bool isUnsigned> template<bool stereo, bool is16Bit, bool isUnsigned>
int16 WrappedMemoryStream<stereo, is16Bit, isUnsigned>::read() { int16 WrappedMemoryStream<stereo, is16Bit, isUnsigned>::read() {
assert(_pos != _end); //assert(_pos != _end);
int16 val = readSample<is16Bit, isUnsigned>(_pos); int16 val = readSample<is16Bit, isUnsigned>(_pos);
_pos += (is16Bit ? 2 : 1); _pos += (is16Bit ? 2 : 1);