[GRASS-SVN] r42808 -
grass/branches/releasebranch_6_4/raster/r.terraflow
svn_grass at osgeo.org
svn_grass at osgeo.org
Fri Jul 16 06:46:39 EDT 2010
Author: mmetz
Date: 2010-07-16 10:46:39 +0000 (Fri, 16 Jul 2010)
New Revision: 42808
Modified:
grass/branches/releasebranch_6_4/raster/r.terraflow/filldepr.cc
Log:
r.terraflow: backport fix for #1006 from devbr
Modified: grass/branches/releasebranch_6_4/raster/r.terraflow/filldepr.cc
===================================================================
--- grass/branches/releasebranch_6_4/raster/r.terraflow/filldepr.cc 2010-07-16 10:46:08 UTC (rev 42807)
+++ grass/branches/releasebranch_6_4/raster/r.terraflow/filldepr.cc 2010-07-16 10:46:39 UTC (rev 42808)
@@ -128,8 +128,10 @@
boundaryType* nextedge;
elevation_type h;
cclabel_type u, v, ur, vr;
+ /* no write op to boundaryStr, no need to call stream_len() each time */
+ off_t nitems = boundaryStr->stream_len();
boundaryStr->seek(0);
- for (size_t i=0; i< boundaryStr->stream_len(); i++) {
+ for (off_t i=0; i< nitems; i++) {
/*read next edge*/
ae = boundaryStr->read_item(&nextedge);
More information about the grass-commit
mailing list