mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-16 14:50:17 +00:00
DIRECTOR: Fix segfault
This commit is contained in:
parent
6b404187fc
commit
2a310ee7e7
@ -155,7 +155,7 @@ bool Channel::isMouseIn(const Common::Point &pos, bool onlyMatte) {
|
||||
return false;
|
||||
|
||||
if (onlyMatte) {
|
||||
if (_sprite->_cast->_type == kCastBitmap) {
|
||||
if (_sprite->_cast && _sprite->_cast->_type == kCastBitmap) {
|
||||
Graphics::Surface *matte = ((BitmapCastMember *)_sprite->_cast)->getMatte();
|
||||
return matte ? !(*(byte *)(matte->getBasePtr(pos.x - bbox.left, pos.y - bbox.top))) : true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user