[GRASS-SVN] r51117 - grass/trunk/vector/v.external
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Mar 19 20:02:08 EDT 2012
Author: martinl
Date: 2012-03-19 17:02:08 -0700 (Mon, 19 Mar 2012)
New Revision: 51117
Modified:
grass/trunk/vector/v.external/args.c
grass/trunk/vector/v.external/main.c
Log:
v.external: fix dsn (missing \0)
Modified: grass/trunk/vector/v.external/args.c
===================================================================
--- grass/trunk/vector/v.external/args.c 2012-03-19 23:58:34 UTC (rev 51116)
+++ grass/trunk/vector/v.external/args.c 2012-03-20 00:02:08 UTC (rev 51117)
@@ -16,8 +16,7 @@
options->dsn->description = _("Examples:\n"
"\t\tESRI Shapefile: directory containing a shapefile\n"
"\t\tMapInfo File: directory containing a mapinfo file\n"
- "\t\tPostGIS database accessed by OGR: PG:dbname=<database> user=grass\n"
- "\t\tPostGIS database accessed directly: dbname=<database> user=grass");
+ "\t\tPostGIS database: connection string, eg. 'PG:dbname=db user=grass'");
options->dsn->required = YES;
options->layer = G_define_option();
Modified: grass/trunk/vector/v.external/main.c
===================================================================
--- grass/trunk/vector/v.external/main.c 2012-03-19 23:58:34 UTC (rev 51116)
+++ grass/trunk/vector/v.external/main.c 2012-03-20 00:02:08 UTC (rev 51117)
@@ -79,6 +79,7 @@
dsn = (char *) G_malloc(length - 3);
for (i = 3; i < length; i++)
dsn[i-3] = options.dsn->answer[i];
+ dsn[length-3] = '\0';
}
else {
dsn = G_store(options.dsn->answer);
More information about the grass-commit
mailing list