[GRASS-SVN] r65132 - in grass/trunk/lib/vector: Vlib diglib
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Apr 25 03:29:22 PDT 2015
Author: martinl
Date: 2015-04-25 03:29:22 -0700 (Sat, 25 Apr 2015)
New Revision: 65132
Modified:
grass/trunk/lib/vector/Vlib/copy.c
grass/trunk/lib/vector/Vlib/write_ogr.c
grass/trunk/lib/vector/Vlib/write_pg.c
grass/trunk/lib/vector/diglib/plus_struct.c
grass/trunk/lib/vector/diglib/struct_alloc.c
Log:
vlib: consolidate debug levels (cosmetics)
Modified: grass/trunk/lib/vector/Vlib/copy.c
===================================================================
--- grass/trunk/lib/vector/Vlib/copy.c 2015-04-25 10:28:41 UTC (rev 65131)
+++ grass/trunk/lib/vector/Vlib/copy.c 2015-04-25 10:29:22 UTC (rev 65132)
@@ -477,7 +477,7 @@
if (nareas > 0)
G_message(_("Exporting areas..."));
for (area = 1; area <= nareas; area++) {
- G_debug(3, "area = %d", area);
+ G_debug(2, "area = %d", area);
G_percent(area, nareas, 3);
/* get category */
Modified: grass/trunk/lib/vector/Vlib/write_ogr.c
===================================================================
--- grass/trunk/lib/vector/Vlib/write_ogr.c 2015-04-25 10:28:41 UTC (rev 65131)
+++ grass/trunk/lib/vector/Vlib/write_ogr.c 2015-04-25 10:29:22 UTC (rev 65132)
@@ -131,7 +131,7 @@
}
if (offset >= ogr_info->offset.array_num) {
- G_warning(_("Invalid offset (%d)"), offset);
+ G_warning(_("Invalid offset (%ld)"), offset);
return -1;
}
@@ -608,13 +608,13 @@
value = db_get_column_value(column);
/* for debug only */
db_convert_column_value_to_string(column, &dbstring);
- G_debug(2, "col %d : val = %s", j,
+ G_debug(3, "col %d : val = %s", j,
db_get_string(&dbstring));
sqltype = db_get_column_sqltype(column);
ctype = db_sqltype_to_Ctype(sqltype);
ogrtype = sqltype_to_ogrtype(sqltype);
- G_debug(2, " colctype = %d", ctype);
+ G_debug(3, " colctype = %d", ctype);
ogrfieldnum = OGR_F_GetFieldIndex(Ogr_feature, colname);
if (ogrfieldnum < 0) {
Modified: grass/trunk/lib/vector/Vlib/write_pg.c
===================================================================
--- grass/trunk/lib/vector/Vlib/write_pg.c 2015-04-25 10:28:41 UTC (rev 65131)
+++ grass/trunk/lib/vector/Vlib/write_pg.c 2015-04-25 10:29:22 UTC (rev 65132)
@@ -277,7 +277,7 @@
}
geom_data = line_to_wkb(pg_info, &points, 1, type, Map->head.with_z);
- G_asprintf(&stmt, "UPDATE \"%s\".\"%s\" SET geom = '%s'::GEOMETRY WHERE %s_id = %d",
+ G_asprintf(&stmt, "UPDATE \"%s\".\"%s\" SET geom = '%s'::GEOMETRY WHERE %s_id = %ld",
schema_name, table_name, geom_data, keycolumn, line);
G_free(geom_data);
@@ -341,7 +341,7 @@
sprintf(stmt, "DELETE FROM %s WHERE %s = %ld",
pg_info->table_name, pg_info->fid_column, fid);
- G_debug(2, "SQL: %s", stmt);
+ G_debug(3, "SQL: %s", stmt);
if (Vect__execute_pg(pg_info->conn, stmt) == -1) {
G_warning(_("Unable to delete feature"));
@@ -2026,7 +2026,7 @@
value = db_get_column_value(column);
/* for debug only */
db_convert_column_value_to_string(column, &dbstmt);
- G_debug(2, "col %d : val = %s", col,
+ G_debug(3, "col %d : val = %s", col,
db_get_string(&dbstmt));
sqltype = db_get_column_sqltype(column);
Modified: grass/trunk/lib/vector/diglib/plus_struct.c
===================================================================
--- grass/trunk/lib/vector/diglib/plus_struct.c 2015-04-25 10:28:41 UTC (rev 65131)
+++ grass/trunk/lib/vector/diglib/plus_struct.c 2015-04-25 10:29:22 UTC (rev 65132)
@@ -416,7 +416,7 @@
int cnt;
struct P_isle *ptr;
- G_debug(3, "dig_Rd_P_isle()");
+ G_debug(4, "dig_Rd_P_isle()");
if (0 >= dig__fread_port_P(&cnt, 1, fp))
return (-1);
Modified: grass/trunk/lib/vector/diglib/struct_alloc.c
===================================================================
--- grass/trunk/lib/vector/diglib/struct_alloc.c 2015-04-25 10:28:41 UTC (rev 65131)
+++ grass/trunk/lib/vector/diglib/struct_alloc.c 2015-04-25 10:29:22 UTC (rev 65132)
@@ -71,7 +71,7 @@
int num;
char *p;
- G_debug(3, "dig_node_alloc_line(): add = %d", add);
+ G_debug(5, "dig_node_alloc_line(): add = %d", add);
num = node->n_lines + add;
@@ -242,7 +242,7 @@
int size;
char *p;
- G_debug(3, "dig_alloc_isle():");
+ G_debug(5, "dig_alloc_isle():");
size = Plus->alloc_isles + 1 + add;
p = G_realloc(Plus->Isle, size * sizeof(struct P_isle *));
if (p == NULL)
@@ -470,7 +470,7 @@
int num;
char *p;
- G_debug(3, "dig_isle_alloc_line():");
+ G_debug(5, "dig_isle_alloc_line():");
num = isle->alloc_lines + add;
p = G_realloc(isle->lines, num * sizeof(plus_t));
More information about the grass-commit
mailing list