浏览代码

vlib: allow writting PostGIS topological elements on level 1

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@54099 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 12 年之前
父节点
当前提交
bfd0d4c427
共有 1 个文件被更改,包括 3 次插入5 次删除
  1. 3 5
      lib/vector/Vlib/write_pg.c

+ 3 - 5
lib/vector/Vlib/write_pg.c

@@ -94,12 +94,10 @@ off_t V1_write_line_pg(struct Map_info *Map, int type,
             return -1;
     }
 
-    if (pg_info->toposchema_name) {
-        G_warning(_("PostGIS topology not supported on level 1"));
-        return -1;
+    if (!pg_info->toposchema_name) { /* simple features */
+        return write_line_sf(Map, type, &points, 1, cats);
     }
-    
-    return write_line_sf(Map, type, &points, 1, cats);
+    return write_line_tp(Map, type, FALSE, points, cats);
 #else
     G_fatal_error(_("GRASS is not compiled with PostgreSQL support"));
     return -1;