summaryrefslogtreecommitdiff
path: root/src/gui/tradewindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/tradewindow.cpp')
-rw-r--r--src/gui/tradewindow.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/tradewindow.cpp b/src/gui/tradewindow.cpp
index 3c1ce60bb..a71b26f60 100644
--- a/src/gui/tradewindow.cpp
+++ b/src/gui/tradewindow.cpp
@@ -458,8 +458,11 @@ void TradeWindow::initTrade(const std::string &nick)
bool TradeWindow::checkItem(const Item *const item) const
{
+ const int itemId = item->getId();
+ if (PlayerInfo::isItemProtected(itemId))
+ return false;
const Item *const tItem = mMyInventory->findItem(
- item->getId(), item->getColor());
+ itemId, item->getColor());
if (tItem && (tItem->getQuantity() > 1
|| item->getQuantity() > 1))