summaryrefslogtreecommitdiff
path: root/src/gui/windows/tradewindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/windows/tradewindow.cpp')
-rw-r--r--src/gui/windows/tradewindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gui/windows/tradewindow.cpp b/src/gui/windows/tradewindow.cpp
index 7d1173856..bf4963daf 100644
--- a/src/gui/windows/tradewindow.cpp
+++ b/src/gui/windows/tradewindow.cpp
@@ -496,6 +496,9 @@ void TradeWindow::initTrade(const std::string &nick)
bool TradeWindow::checkItem(const Item *const item) const
{
+ if (!item)
+ return false;
+
const int itemId = item->getId();
if (PlayerInfo::isItemProtected(itemId))
return false;