Fix T65049 Crash cause by NULL geom pointer

This commit is contained in:
2019-05-30 18:28:05 +02:00
parent 8a4a05ae85
commit 8f4b7083d3

View File

@@ -154,7 +154,9 @@ static void basic_cache_populate(void *vedata, Object *ob)
if (is_flat_object_viewed_from_side) {
/* Avoid losing flat objects when in ortho views (see T56549) */
struct GPUBatch *geom = DRW_cache_object_all_edges_get(ob);
DRW_shgroup_call(stl->g_data->depth_shgrp, geom, ob);
if (geom) {
DRW_shgroup_call(stl->g_data->depth_shgrp, geom, ob);
}
return;
}
}