From 0c6c03bfd6ed0d85564c5b074f38095c2b796245 Mon Sep 17 00:00:00 2001 From: Sylvain Dupont Date: Sun, 10 Oct 2010 21:19:40 +0000 Subject: [PATCH] TOON: Fix potential undefined operation warning svn-id: r53131 --- engines/toon/tools.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/engines/toon/tools.cpp b/engines/toon/tools.cpp index 266effe7596..a03a2d57cee 100644 --- a/engines/toon/tools.cpp +++ b/engines/toon/tools.cpp @@ -499,8 +499,10 @@ int32 RncDecoder::unpackM2(const void *input, void *output) { ofs_lo = *_srcPtr++; ofs = (ofs_hi << 8) | ofs_lo; - while (len--) - *_dstPtr++ = *(byte *)(_dstPtr - ofs - 1); + while (len--) { + *_dstPtr = *(byte *)(_dstPtr - ofs - 1); + _dstPtr++; + } }