[GRASS-SVN] r48941 - grass/trunk/lib/vector/Vlib
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Oct 25 16:00:10 EDT 2011
Author: martinl
Date: 2011-10-25 13:00:10 -0700 (Tue, 25 Oct 2011)
New Revision: 48941
Modified:
grass/trunk/lib/vector/Vlib/write_ogr.c
Log:
vlib/ogr: don't try to write attributes if no dblink is defined
Modified: grass/trunk/lib/vector/Vlib/write_ogr.c
===================================================================
--- grass/trunk/lib/vector/Vlib/write_ogr.c 2011-10-25 19:16:07 UTC (rev 48940)
+++ grass/trunk/lib/vector/Vlib/write_ogr.c 2011-10-25 20:00:10 UTC (rev 48941)
@@ -72,7 +72,7 @@
}
cat = -1; /* no attributes to be written */
- if (cats->n_cats > 0) {
+ if (cats->n_cats > 0 && Map->dblnk->n_fields > 0) {
/* check for attributes */
Fi = Vect_get_dblink(Map, 0);
if (Fi) {
More information about the grass-commit
mailing list