[GRASS-SVN] r59936 - grass/branches/releasebranch_7_0/vector/v.external.out
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Apr 24 07:08:56 PDT 2014
Author: martinl
Date: 2014-04-24 07:08:56 -0700 (Thu, 24 Apr 2014)
New Revision: 59936
Modified:
grass/branches/releasebranch_7_0/vector/v.external.out/status.c
Log:
v.external.out: print dsn for PostgreSQL format
(merge r59909 from trunk)
Modified: grass/branches/releasebranch_7_0/vector/v.external.out/status.c
===================================================================
--- grass/branches/releasebranch_7_0/vector/v.external.out/status.c 2014-04-24 13:18:05 UTC (rev 59935)
+++ grass/branches/releasebranch_7_0/vector/v.external.out/status.c 2014-04-24 14:08:56 UTC (rev 59936)
@@ -61,11 +61,16 @@
G_fatal_error(_("OGR format not defined"));
}
else { /* PG */
+ char dsn_name[GNAME_MAX];
+
/* conninfo (required) */
p = G_find_key_value("conninfo", key_val);
if (!p)
G_fatal_error(_("PG connection info (conninfo) not defined"));
-
+
+ /* print also dsn for compatibility */
+ sprintf(dsn_name, "PG:%s", p);
+ G_set_key_value("dsn", dsn_name, key_val);
/* force format */
print_key_value("format", "PostgreSQL", shell);
}
More information about the grass-commit
mailing list