Fix [#21657] Blender crashes after importing .obj and selecting a material

Creating an object via some pre-existing obdata via the py api wasn't properly initialising the 
object/mesh material link data.
This commit is contained in:
Matt Ebb 2010-03-18 06:03:41 +00:00
parent 6c6825b536
commit d96bf316ac

@ -156,6 +156,8 @@ Object *rna_Main_objects_new(Main *bmain, ReportList *reports, char* name, ID *d
ob->id.us--;
ob->data= data;
test_object_materials(ob->data);
return ob;
}