]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fix a C++ void pointer error
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 9 Aug 2010 17:29:15 +0000 (17:29 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 9 Aug 2010 17:29:15 +0000 (17:29 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10382 d7cf8633-e32d-0410-b094-e92efae38249

model_brush.c

index 3cfca8c96ef80b9a6544ef7fd1d758efba12478e..70acef81d982f2d0546d977246c0ba7f6e8bb228 100644 (file)
@@ -7382,7 +7382,7 @@ void Mod_OBJ_Load(dp_model_t *mod, void *buffer, void *bufferend)
        loadmodel->num_surfaces = 0;
        // allocate storage for the worst case number of surfaces, later we resize
        tempsurfaces = (msurface_t *)Mem_Alloc(loadmodel->mempool, numtextures * loadmodel->brush.numsubmodels * sizeof(msurface_t));
-       submodelfirstsurface = Mem_Alloc(loadmodel->mempool, (loadmodel->brush.numsubmodels+1) * sizeof(int));
+       submodelfirstsurface = (int *)Mem_Alloc(loadmodel->mempool, (loadmodel->brush.numsubmodels+1) * sizeof(int));
        surface = tempsurfaces;
        for (submodelindex = 0;submodelindex < loadmodel->brush.numsubmodels;submodelindex++)
        {