diff options
Diffstat (limited to 'src/net/tmwa/buysellhandler.cpp')
-rw-r--r-- | src/net/tmwa/buysellhandler.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/net/tmwa/buysellhandler.cpp b/src/net/tmwa/buysellhandler.cpp index c44b2ebbf..a51e0c7b1 100644 --- a/src/net/tmwa/buysellhandler.cpp +++ b/src/net/tmwa/buysellhandler.cpp @@ -95,14 +95,14 @@ void BuySellHandler::handleMessage(Net::MessageIn &msg) void BuySellHandler::processNpcBuy(Net::MessageIn &msg) { msg.readInt16(); // length - int sz = 11; + unsigned int sz = 11; if (serverVersion > 0) sz += 1; - const int n_items = (msg.getLength() - 4) / sz; + const unsigned int n_items = (msg.getLength() - 4U) / sz; mBuyDialog = new BuyDialog(mNpcId); mBuyDialog->setMoney(PlayerInfo::getAttribute(Attributes::MONEY)); - for (int k = 0; k < n_items; k++) + for (unsigned int k = 0; k < n_items; k++) { const int value = msg.readInt32(); msg.readInt32(); // DCvalue |