Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Unified Diff: third_party/sqlite/src/src/test_fs.c

Issue 2751253002: [sql] Import SQLite 3.17.0. (Closed)
Patch Set: also clang on Linux i386 Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/sqlite/src/src/test_devsym.c ('k') | third_party/sqlite/src/src/test_func.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/src/test_fs.c
diff --git a/third_party/sqlite/src/src/test_fs.c b/third_party/sqlite/src/src/test_fs.c
index 45db0b53b8ae5dffd88d2b7e77bc6894c5a112de..dd590a66232fb5b93ba80e258e8c4e8d43e1ecec 100644
--- a/third_party/sqlite/src/src/test_fs.c
+++ b/third_party/sqlite/src/src/test_fs.c
@@ -62,7 +62,11 @@
** SELECT * FROM fstree WHERE path LIKE '/home/dan/sqlite/%'
*/
#include "sqliteInt.h"
-#include "tcl.h"
+#if defined(INCLUDE_SQLITE_TCL_H)
+# include "sqlite_tcl.h"
+#else
+# include "tcl.h"
+#endif
#include <stdlib.h>
#include <string.h>
@@ -495,10 +499,14 @@ static int fstreeFilter(
char aWild[2] = { '\0', '\0' };
#if SQLITE_OS_WIN
- zRoot = sqlite3_mprintf("%s%c", getenv("SystemDrive"), '/');
- nRoot = strlen(zRoot);
- zPrefix = sqlite3_mprintf("%s", getenv("SystemDrive"));
- nPrefix = strlen(zPrefix);
+ const char *zDrive = windirent_getenv("fstreeDrive");
+ if( zDrive==0 ){
+ zDrive = windirent_getenv("SystemDrive");
+ }
+ zRoot = sqlite3_mprintf("%s%c", zDrive, '/');
+ nRoot = sqlite3Strlen30(zRoot);
+ zPrefix = sqlite3_mprintf("%s", zDrive);
+ nPrefix = sqlite3Strlen30(zPrefix);
#else
zRoot = "/";
nRoot = 1;
@@ -871,7 +879,7 @@ extern int getDbPointer(Tcl_Interp *interp, const char *zA, sqlite3 **ppDb);
/*
** Register the echo virtual table module.
*/
-static int register_fs_module(
+static int SQLITE_TCLAPI register_fs_module(
ClientData clientData, /* Pointer to sqlite3_enable_XXX function */
Tcl_Interp *interp, /* The TCL interpreter that invoked this command */
int objc, /* Number of arguments */
« no previous file with comments | « third_party/sqlite/src/src/test_devsym.c ('k') | third_party/sqlite/src/src/test_func.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698