summaryrefslogtreecommitdiffstats
path: root/crawl-ref
diff options
context:
space:
mode:
authorDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-09-25 10:45:13 -0500
committerDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-09-25 10:45:13 -0500
commit5746c281907b262e6be852da8aa566ca2f674824 (patch)
treebd6cb2ab8191596a309e7166ef7132200a84eeb1 /crawl-ref
parenta6215ebe547de168b593c98e7d3b1e5a82bbc409 (diff)
parent046f84f16011c1911d178a70778cdaab77590bbc (diff)
downloadcrawl-ref-5746c281907b262e6be852da8aa566ca2f674824.tar.gz
crawl-ref-5746c281907b262e6be852da8aa566ca2f674824.zip
Merge branch 'master' of ssh://crawl-ref.git.sourceforge.net/gitroot/crawl-ref/crawl-ref
Diffstat (limited to 'crawl-ref')
-rw-r--r--crawl-ref/source/makeitem.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/crawl-ref/source/makeitem.cc b/crawl-ref/source/makeitem.cc
index e5d97ce3d5..a5e22e7df3 100644
--- a/crawl-ref/source/makeitem.cc
+++ b/crawl-ref/source/makeitem.cc
@@ -3030,6 +3030,9 @@ static void _give_monster_item(monsters *mon, int thing,
bool force_item = false,
bool (monsters::*pickupfn)(item_def&, int) = NULL)
{
+ if (thing == NON_ITEM || thing == -1)
+ return;
+
item_def &mthing = mitm[thing];
ASSERT(is_valid_item(mthing));