Ensure that the parser doesn't read past end of message