[GRASS-SVN] r33631 - grass/trunk/lib/gis
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Sep 30 20:57:14 EDT 2008
Author: glynn
Date: 2008-09-30 20:57:14 -0400 (Tue, 30 Sep 2008)
New Revision: 33631
Modified:
grass/trunk/lib/gis/opencell.c
Log:
Zero fileinfo structures upon allocation
Modified: grass/trunk/lib/gis/opencell.c
===================================================================
--- grass/trunk/lib/gis/opencell.c 2008-09-30 22:44:42 UTC (rev 33630)
+++ grass/trunk/lib/gis/opencell.c 2008-10-01 00:57:14 UTC (rev 33631)
@@ -42,8 +42,10 @@
G__.fileinfo = G_realloc(G__.fileinfo, newsize * sizeof(struct fileinfo));
/* Mark all cell files as closed */
- for (i = oldsize; i < newsize; i++)
+ for (i = oldsize; i < newsize; i++) {
+ memset(&G__.fileinfo[i], 0, sizeof(struct fileinfo));
G__.fileinfo[i].open_mode = -1;
+ }
G__.fileinfo_count = newsize;
More information about the grass-commit
mailing list