[GRASS-SVN] r33690 - grass/trunk/lib/gis

svn_grass at osgeo.org svn_grass at osgeo.org
Mon Oct 6 05:47:14 EDT 2008


Author: glynn
Date: 2008-10-06 05:47:14 -0400 (Mon, 06 Oct 2008)
New Revision: 33690

Modified:
   grass/trunk/lib/gis/opencell.c
Log:
Ensure that fcb->gdal is either set or cleared, not left uninitialised


Modified: grass/trunk/lib/gis/opencell.c
===================================================================
--- grass/trunk/lib/gis/opencell.c	2008-10-06 09:44:29 UTC (rev 33689)
+++ grass/trunk/lib/gis/opencell.c	2008-10-06 09:47:14 UTC (rev 33690)
@@ -303,9 +303,8 @@
     if ((fcb->reclass_flag = reclass_flag))
 	G_copy(&fcb->reclass, &reclass, sizeof(reclass));
 
-    if (gdal)
-	fcb->gdal = gdal;
-    else
+    fcb->gdal = gdal;
+    if (!gdal)
 	/* check for compressed data format, making initial reads if necessary */
 	if (G__check_format(fd) < 0) {
 	    close(fd);		/* warning issued by check_format() */



More information about the grass-commit mailing list