diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2018-10-10 15:30:44 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2018-10-10 15:30:44 +0300 |
commit | 1fad887d9e22da97009f28288cc6f21cc32a6c37 (patch) | |
tree | a212dbd568657b4351b4b5c68b80aeea122fadef /source | |
parent | 84cf670d1d86f69aecbb6307aa49650e958d7845 (diff) |
Fix T57130: Crash when running 'set active object as camera' on an empty
Reviewed By: brecht
https://developer.blender.org/D3782
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/draw/modes/object_mode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/draw/modes/object_mode.c b/source/blender/draw/modes/object_mode.c index 2901a718d59..20abfbf3348 100644 --- a/source/blender/draw/modes/object_mode.c +++ b/source/blender/draw/modes/object_mode.c @@ -634,7 +634,7 @@ static void OBJECT_engine_init(void *vedata) } float dist; - if (rv3d->persp == RV3D_CAMOB && v3d->camera) { + if (rv3d->persp == RV3D_CAMOB && v3d->camera && v3d->camera->type == OB_CAMERA) { Object *camera_object = DEG_get_evaluated_object(draw_ctx->depsgraph, v3d->camera); dist = ((Camera *)(camera_object->data))->clipend; } |