summaryrefslogtreecommitdiff
path: root/src/map/magic-interpreter-base.cpp
diff options
context:
space:
mode:
authorBen Longbons <b.r.longbons@gmail.com>2013-10-12 18:41:40 -0700
committerBen Longbons <b.r.longbons@gmail.com>2013-10-12 18:41:40 -0700
commitedd67db458188a76934b963e6a40f7b681f86b3d (patch)
treec8dec729b3f539ba027b1b3559598dbad0a70546 /src/map/magic-interpreter-base.cpp
parent524df2190b855c4096449a1aaa7b92a15875f7a7 (diff)
downloadtmwa-edd67db458188a76934b963e6a40f7b681f86b3d.tar.gz
tmwa-edd67db458188a76934b963e6a40f7b681f86b3d.tar.bz2
tmwa-edd67db458188a76934b963e6a40f7b681f86b3d.tar.xz
tmwa-edd67db458188a76934b963e6a40f7b681f86b3d.zip
Disallow unchecked being casts
Despite the fact that that's what the code always did, it was sometimes wrong.
Diffstat (limited to 'src/map/magic-interpreter-base.cpp')
-rw-r--r--src/map/magic-interpreter-base.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/magic-interpreter-base.cpp b/src/map/magic-interpreter-base.cpp
index 09656c6..e86e86b 100644
--- a/src/map/magic-interpreter-base.cpp
+++ b/src/map/magic-interpreter-base.cpp
@@ -415,7 +415,7 @@ void spell_update_location(dumb_ptr<invocation> invocation)
dumb_ptr<block_list> owner_bl = map_id2bl(invocation->subject);
if (!owner_bl)
return;
- dumb_ptr<map_session_data> owner = owner_bl->as_player();
+ dumb_ptr<map_session_data> owner = owner_bl->is_player();
spell_set_location(invocation, owner);
}