[GRASS-SVN] r59364 - grass/trunk/db/db.connect
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Mar 26 07:50:37 PDT 2014
Author: martinl
Date: 2014-03-26 07:50:36 -0700 (Wed, 26 Mar 2014)
New Revision: 59364
Modified:
grass/trunk/db/db.connect/main.c
Log:
db.connect: use HOST_DIRSEP on Windows (only for dbf and sqlite driver)
Modified: grass/trunk/db/db.connect/main.c
===================================================================
--- grass/trunk/db/db.connect/main.c 2014-03-26 14:50:30 UTC (rev 59363)
+++ grass/trunk/db/db.connect/main.c 2014-03-26 14:50:36 UTC (rev 59364)
@@ -152,6 +152,18 @@
*c = '\0';
sprintf(database, "%s%s%s", buf, G_mapset(), c + 7);
}
+#ifdef __MINGW32__
+ if (strcmp(conn.driverName, "sqlite") == 0 |
+ strcmp(conn.driverName, "dbf") == 0) {
+ char *p;
+ p = database;
+ while(*p) {
+ if (*p == '/')
+ *p = HOST_DIRSEP;
+ p++;
+ }
+ }
+#endif
}
else {
database[0] = '\0';
More information about the grass-commit
mailing list