浏览代码

vlib/pg: fix copying map features for external formats when using temporary maps

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

+ 2 - 1
lib/vector/Vlib/copy.c

@@ -82,7 +82,8 @@ int Vect_copy_map_lines_field(struct Map_info *In, int field,
         G_fatal_error(_("Unable to copy features. Input vector map <%s> is not open"),
         G_fatal_error(_("Unable to copy features. Input vector map <%s> is not open"),
                       Vect_get_full_name(In));
                       Vect_get_full_name(In));
 
 
-    format = Vect_maptype(Out);
+    format = Out->format; /* do not use Vect_maptype(), we need native
+                             format for temporary maps here */
     topo = TOPO_NONE;
     topo = TOPO_NONE;
     if (format == GV_FORMAT_NATIVE) {
     if (format == GV_FORMAT_NATIVE) {
         topo = TOPO_NATIVE;
         topo = TOPO_NATIVE;