Null pointer check exiting sculpt mode

Needed for 2.8x, harmless here.
This commit is contained in:
Campbell Barton 2018-02-28 23:23:48 +11:00
parent 8a7eb6c4c1
commit e7aca5bd3c
1 changed files with 1 additions and 1 deletions

View File

@ -1144,7 +1144,7 @@ static void ed_vwpaintmode_exit_generic(
}
/* If the cache is not released by a cancel or a done, free it now. */
if (ob->sculpt->cache) {
if (ob->sculpt && ob->sculpt->cache) {
sculpt_cache_free(ob->sculpt->cache);
ob->sculpt->cache = NULL;
}