[GRASS-SVN] r59431 - grass/trunk/raster/r.in.xyz
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Mar 27 08:12:26 PDT 2014
Author: wenzeslaus
Date: 2014-03-27 08:12:26 -0700 (Thu, 27 Mar 2014)
New Revision: 59431
Modified:
grass/trunk/raster/r.in.xyz/main.c
Log:
r.in.xyz: close the input file when it should be closed (variable was not set, so behavior was random)
Modified: grass/trunk/raster/r.in.xyz/main.c
===================================================================
--- grass/trunk/raster/r.in.xyz/main.c 2014-03-27 15:10:48 UTC (rev 59430)
+++ grass/trunk/raster/r.in.xyz/main.c 2014-03-27 15:12:26 UTC (rev 59431)
@@ -535,6 +535,7 @@
infile = G_store("stdin"); /* filename for history metadata */
}
else {
+ from_stdin = FALSE;
if ((in_fp = fopen(infile, "r")) == NULL)
G_fatal_error(_("Unable to open input file <%s>"), infile);
}
@@ -560,6 +561,7 @@
scan_bounds(in_fp, xcol, ycol, zcol, vcol, fs, shell_style->answer,
skipline->answer, zscale, vscale);
+ /* close input file */
if (!from_stdin)
fclose(in_fp);
More information about the grass-commit
mailing list