[GRASS-SVN] r67579 - grass/branches/releasebranch_7_0/lib/vector/vedit
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Jan 13 13:09:58 PST 2016
Author: martinl
Date: 2016-01-13 13:09:58 -0800 (Wed, 13 Jan 2016)
New Revision: 67579
Modified:
grass/branches/releasebranch_7_0/lib/vector/vedit/break.c
Log:
vedit vector lib: forward port r58512 and r58516 (fixing #719: unexpected line with v.edit tool=break)
(merge r67577 from trunk)
Modified: grass/branches/releasebranch_7_0/lib/vector/vedit/break.c
===================================================================
--- grass/branches/releasebranch_7_0/lib/vector/vedit/break.c 2016-01-13 13:01:32 UTC (rev 67578)
+++ grass/branches/releasebranch_7_0/lib/vector/vedit/break.c 2016-01-13 21:09:58 UTC (rev 67579)
@@ -85,6 +85,7 @@
G_debug(3, "Vedit_split_lines(): line=%d", line);
/* copy first line part */
+ Vect_reset_line(Points2);
for (l = 0; l < seg; l++) {
Vect_append_point(Points2, x[l], y[l], z[l]);
}
@@ -93,7 +94,10 @@
Vect_append_point(Points2, px, py, 0.0);
/* rewrite the line */
- newline = Vect_rewrite_line(Map, line, type, Points2, Cats);
+ if (j == 0)
+ newline = Vect_rewrite_line(Map, line, type, Points2, Cats);
+ else
+ newline = Vect_write_line(Map, type, Points2, Cats);
if (newline < 0) {
return -1;
}
More information about the grass-commit
mailing list