From a643a8cc8a1f51e5b628f14be128b1cfa06a2818 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torbj=C3=B6rn=20Andersson?= Date: Wed, 23 Apr 2008 17:39:13 +0000 Subject: [PATCH] Fixed warning about potentially undefined behaviour. svn-id: r31667 --- engines/made/redreader.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/engines/made/redreader.cpp b/engines/made/redreader.cpp index 96ed2a4c153..a8694b26ec3 100644 --- a/engines/made/redreader.cpp +++ b/engines/made/redreader.cpp @@ -288,7 +288,9 @@ void LzhDecompressor::make_table(uint nchar, byte bitlen[], uint tablebits, uint start[i] >>= jutbits; weight[i] = 1U << (tablebits - i); } - while (i <= 16) weight[i++] = 1U << (16 - i); + for (; i <= 16; i++) { + weight[i] = 1U << (16 - i); + } i = start[tablebits + 1] >> jutbits; if (i != (uint16)(1U << 16)) { k = 1U << tablebits;