Add a couple of asserts to explain stuff to Coverity