File yafray-0.0.9-gcc4-64bit.patch of Package yafray

One Yafray developer comfirmed that the code is correct and that there are
really integer values saved as pointers. Also he said that this code converts
the integers (indexes) to pointers. This explains the lines like:
(*i).a=&(mesh->points->points)[n]; where pointers are saved in the problematic
variables that hold integer values a few lines above.
See http://projects.blender.org/tracker/?func=detail&atid=290&aid=2555&group_id=66,
for more details.
================================================================================
--- src/loader/render.cc
+++ src/loader/render.cc
@@ -723,21 +723,21 @@
 	}
 	for(vector<triangle_t>::iterator i=faces.begin();i!=faces.end();++i)
 	{
-		long int n=(long int)((*i).a);
-		if((n>=(long int)mesh->points->points.size()) || (n<0))
+		intptr_t n=(intptr_t)((*i).a);
+		if((n>=(intptr_t)mesh->points->points.size()) || (n<0))
 			{ WARNING<<"Point "<<n<<" out of bounds in object\n"; n=0; }
 		(*i).a=&(mesh->points->points)[n];
-		n=(long int)((*i).b);
-		if((n>=(long int)mesh->points->points.size()) || (n<0))
+		n=(intptr_t)((*i).b);
+		if((n>=(intptr_t)mesh->points->points.size()) || (n<0))
 			{ WARNING<<"Point "<<n<<" out of bounds in object\n"; n=0; }
 		(*i).b=&(mesh->points->points)[n];
-		n=(long int)((*i).c);
-		if((n>=(long int)mesh->points->points.size()) || (n<0))
+		n=(intptr_t)((*i).c);
+		if((n>=(intptr_t)mesh->points->points.size()) || (n<0))
 			{ WARNING<<"Point "<<n<<" out of bounds in object\n"; n=0; }
 		(*i).c=&(mesh->points->points)[n];
 		
 		(*i).recNormal();
-		long int ishader=(long int)(*i).getShader();
+		intptr_t ishader=(intptr_t)(*i).getShader();
 		if(ishader<0) 
 			(*i).setShader(NULL);
 		else