Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-10-31 13:50:24 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-10-31 13:50:24 +0400
commit12ed0c64bc7062f46cd1307b5566e99064330733 (patch)
tree82d27db755d250546cc5edf61addd701c8f4cdbd /source/blender/blenloader
parent26748efc037ccc069e1a08642d124bdfc50c6862 (diff)
make use customdata typeoffset more, add an assert to ensure its to date.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 02016b2597d..b49e392d1f4 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -3824,7 +3824,7 @@ static void direct_link_customdata(FileData *fd, CustomData *data, int count)
/* annoying workaround for bug [#31079] loading legacy files with
* no polygons _but_ have stale customdata */
if (UNLIKELY(count == 0 && data->layers == NULL && data->totlayer != 0)) {
- memset(data, 0, sizeof(*data));
+ CustomData_reset(data);
return;
}
@@ -8098,6 +8098,7 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
{
Mesh *me;
for (me = main->mesh.first; me; me = me->id.next) {
+ CustomData_update_typemap(&me->vdata);
CustomData_free_layers(&me->vdata, CD_MSTICKY, me->totvert);
}
}