[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [38067] branches/bmesh/blender/source/ blender: fixing compile errors with VisualStudio 2008.

Andrea Weikert elubie at gmx.net
Sun Jul 3 19:07:07 CEST 2011


Revision: 38067
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38067
Author:   elubie
Date:     2011-07-03 17:07:07 +0000 (Sun, 03 Jul 2011)
Log Message:
-----------
fixing compile errors with VisualStudio 2008.
* macro ABS has no effect with uintptr_t anyway and was throwing warning (promoted to error) -> commented out and marked with TODO
* removed two unused variables trhowing warning also promoted to error when compiling.

Modified Paths:
--------------
    branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c
    branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c
    branches/bmesh/blender/source/blender/blenlib/BLI_smallhash.h

Modified: branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c
===================================================================
--- branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c	2011-07-03 17:05:24 UTC (rev 38066)
+++ branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c	2011-07-03 17:07:07 UTC (rev 38067)
@@ -1334,7 +1334,7 @@
 {
 	EditDerivedBMesh *bmdm = (EditDerivedBMesh *)dm;
 	BMesh *bm = ((EditDerivedBMesh *)dm)->tc->bm;
-	BMIter iter, liter;
+	BMIter iter;
 	BMFace *f;
 	int i, j;
 

Modified: branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c
===================================================================
--- branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c	2011-07-03 17:05:24 UTC (rev 38066)
+++ branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c	2011-07-03 17:07:07 UTC (rev 38067)
@@ -2621,7 +2621,7 @@
 	float *w = NULL;
 	WeightTable wtable = {0};
 	MCol *mcol;
-	MEdge *medge = NULL, medge2;
+	MEdge *medge = NULL;
 	MFace *mface = NULL;
 	MPoly *mpoly = NULL;
 

Modified: branches/bmesh/blender/source/blender/blenlib/BLI_smallhash.h
===================================================================
--- branches/bmesh/blender/source/blender/blenlib/BLI_smallhash.h	2011-07-03 17:05:24 UTC (rev 38066)
+++ branches/bmesh/blender/source/blender/blenlib/BLI_smallhash.h	2011-07-03 17:07:07 UTC (rev 38067)
@@ -100,7 +100,7 @@
 {
 	int h, hoff=1;
 
-	key = ABS(key);
+	/* key = ABS(key); TODO: XXXXX this throws error with MSVC (warning as error) */
 
 	if (hash->size < hash->used*3) {
 		int newsize = hashsizes[++hash->curhash];
@@ -156,7 +156,7 @@
 {
 	int h, hoff=1;
 
-	key = ABS(key);
+	/* key = ABS(key); TODO: XXXXX this throws error with MSVC (warning as error) */
 	h = key;
 	
 	while (hash->table[h % hash->size].key != key 
@@ -176,7 +176,7 @@
 {
 	int h, hoff=1;
 
-	key = ABS(key);
+	/* key = ABS(key); TODO: XXXXX this throws error with MSVC (warning as error) */
 	h = key;
 	
 	if (!hash->table)
@@ -196,8 +196,9 @@
 
 BM_INLINE int BLI_smallhash_haskey(SmallHash *hash, uintptr_t key)
 {
-	int h = ABS(key), hoff=1;
-	key = ABS(key);
+	int h = key, hoff=1;
+	h = ABS(h);
+	/* key = ABS(key); TODO: XXXXX this throws error with MSVC (warning as error) */
 	
 	if (!hash->table)
 		return 0;




More information about the Bf-blender-cvs mailing list