diff --git a/code/COBLoader.cpp b/code/COBLoader.cpp index 571423705..677562150 100644 --- a/code/COBLoader.cpp +++ b/code/COBLoader.cpp @@ -938,8 +938,9 @@ public: ~chunk_guard() { // don't do anything if the size is not given - nfo.size != static_cast(-1) ? reader.IncPtr(static_cast(nfo.size)- - reader.GetCurrentPos()+cur) : 0; + if(nfo.size != static_cast(-1)) { + reader.IncPtr(static_cast(nfo.size)-reader.GetCurrentPos()+cur); + } } private: