[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [60596] trunk/blender: fix for crash on load if the file was saved in editmesh,
Campbell Barton
ideasman42 at gmail.com
Mon Oct 7 18:48:27 CEST 2013
Revision: 60596
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=60596
Author: campbellbarton
Date: 2013-10-07 16:48:26 +0000 (Mon, 07 Oct 2013)
Log Message:
-----------
fix for crash on load if the file was saved in editmesh,
BKE_mesh_uv_cdlayer_rename_index was checking editmesh pointer before it was NULL'd by direct_link_mesh.
Modified Paths:
--------------
trunk/blender/CMakeLists.txt
trunk/blender/source/blender/blenloader/intern/readfile.c
Modified: trunk/blender/CMakeLists.txt
===================================================================
--- trunk/blender/CMakeLists.txt 2013-10-07 16:07:55 UTC (rev 60595)
+++ trunk/blender/CMakeLists.txt 2013-10-07 16:48:26 UTC (rev 60596)
@@ -372,7 +372,7 @@
endif()
if(NOT CMAKE_OSX_DEPLOYMENT_TARGET)
- set(CMAKE_OSX_DEPLOYMENT_TARGET "10.5" CACHE STRING "" FORCE) # 10.5 is our min. target, if you use higher sdk, weak linking happens
+ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.5" CACHE STRING "" FORCE) # 10.5 is our min. target, if you use higher sdk, weak linking happens
endif()
if(NOT ${CMAKE_GENERATOR} MATCHES "Xcode")
Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/readfile.c 2013-10-07 16:07:55 UTC (rev 60595)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c 2013-10-07 16:48:26 UTC (rev 60596)
@@ -4164,12 +4164,6 @@
direct_link_customdata(fd, &mesh->fdata, mesh->totface);
direct_link_customdata(fd, &mesh->ldata, mesh->totloop);
direct_link_customdata(fd, &mesh->pdata, mesh->totpoly);
-
- if (mesh->mloopuv || mesh->mtpoly) {
- /* for now we have to ensure texpoly and mloopuv layers are aligned
- * in the future we may allow non-aligned layers */
- BKE_mesh_cd_validate(mesh);
- }
mesh->bb = NULL;
mesh->edit_btmesh = NULL;
@@ -4179,6 +4173,12 @@
mesh->totselect = 0;
}
+ if (mesh->mloopuv || mesh->mtpoly) {
+ /* for now we have to ensure texpoly and mloopuv layers are aligned
+ * in the future we may allow non-aligned layers */
+ BKE_mesh_cd_validate(mesh);
+ }
+
/* Multires data */
mesh->mr= newdataadr(fd, mesh->mr);
if (mesh->mr) {
More information about the Bf-blender-cvs
mailing list