[GRASS-SVN] r49416 - grass/trunk/vector/v.category
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Nov 29 02:42:42 EST 2011
Author: mmetz
Date: 2011-11-28 23:42:42 -0800 (Mon, 28 Nov 2011)
New Revision: 49416
Modified:
grass/trunk/vector/v.category/main.c
Log:
v.category: always copy cats for option=transfer
Modified: grass/trunk/vector/v.category/main.c
===================================================================
--- grass/trunk/vector/v.category/main.c 2011-11-28 22:50:09 UTC (rev 49415)
+++ grass/trunk/vector/v.category/main.c 2011-11-29 07:42:42 UTC (rev 49416)
@@ -308,17 +308,13 @@
if (type & otype && (!Clist ||
(Clist &&
Vect_cat_in_cat_list(id, Clist) == TRUE))) {
- if ((Vect_cat_get(Cats, fields[1], &ocat)) == 0) {
- if (ocat < 0) {
- int n = Cats->n_cats;
-
- for (i = 0; i < n; i++) {
- if (Cats->field[i] == fields[0]) {
- scat = Cats->cat[i];
- if (Vect_cat_set(Cats, fields[1], scat) > 0) {
- nmodified++;
- }
- }
+ int n = Cats->n_cats;
+
+ for (i = 0; i < n; i++) {
+ if (Cats->field[i] == fields[0]) {
+ scat = Cats->cat[i];
+ if (Vect_cat_set(Cats, fields[1], scat) > 0) {
+ nmodified++;
}
}
}
More information about the grass-commit
mailing list