]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
Oops... It seems this malloc/free was actually intended (part of a piece of code...
authormolivier <molivier@d7cf8633-e32d-0410-b094-e92efae38249>
Fri, 2 Apr 2004 07:27:05 +0000 (07:27 +0000)
committermolivier <molivier@d7cf8633-e32d-0410-b094-e92efae38249>
Fri, 2 Apr 2004 07:27:05 +0000 (07:27 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4077 d7cf8633-e32d-0410-b094-e92efae38249

cl_particles.c

index 18ad1fc550259316b6819e8afdfb806a9613d7eb..790abe05826c89efc035c87814271b1fde9f032f 100644 (file)
@@ -88,7 +88,7 @@ void fractalnoise(qbyte *noise, int size, int startgrid)
        startgrid = bound(0, startgrid, size);
 
        amplitude = 0xFFFF; // this gets halved before use
-       noisebuf = Mem_Alloc (tempmempool, size * size * sizeof (*noisebuf));
+       noisebuf = malloc(size*size*sizeof(int));
        memset(noisebuf, 0, size*size*sizeof(int));
 
        for (g2 = startgrid;g2;g2 >>= 1)
@@ -130,7 +130,7 @@ void fractalnoise(qbyte *noise, int size, int startgrid)
        for (y = 0;y < size;y++)
                for (x = 0;x < size;x++)
                        *noise++ = (qbyte) (((n(x,y) - min) * 256) / max);
-       Mem_Free (noisebuf);
+       free(noisebuf);
 #undef n
 }
 void VectorVectors(const vec3_t forward, vec3_t right, vec3_t up)