From 551867485ca9d6afc3aa99f28814f948b79ceefb Mon Sep 17 00:00:00 2001 From: Martchus Date: Sat, 6 Aug 2016 21:20:25 +0200 Subject: [PATCH] Throw IO failure always via throwIoFailure --- io/bitreader.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/io/bitreader.h b/io/bitreader.h index c2f0332..290a5f2 100644 --- a/io/bitreader.h +++ b/io/bitreader.h @@ -3,6 +3,7 @@ #include "../conversion/types.h" #include "../application/global.h" +#include "../io/catchiofailure.h" #include #include @@ -70,7 +71,7 @@ intType BitReader::readBits(byte bitCount) for(byte readAtOnce; bitCount; bitCount -= readAtOnce) { if(!m_bitsAvail) { if(++m_buffer >= m_end) { - throw std::ios_base::failure("end of buffer exceeded"); + throwIoFailure("end of buffer exceeded"); } m_bitsAvail = 8; }