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

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

Issue 949043002: Add //third_party/sqlite to dirs_to_snapshot, remove net_sql.patch (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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_config.c ('k') | third_party/sqlite/src/src/test_fs.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_demovfs.c
diff --git a/third_party/sqlite/src/src/test_demovfs.c b/third_party/sqlite/src/src/test_demovfs.c
index e56e8065cfbcd3cb73cfbf5d3535265b130998e8..c63b0a8b7a19bc398e1edb5d523757f2a0973e88 100644
--- a/third_party/sqlite/src/src/test_demovfs.c
+++ b/third_party/sqlite/src/src/test_demovfs.c
@@ -10,14 +10,12 @@
**
*************************************************************************
**
-** An example of a simple VFS implementation that omits complex features
-** often not required or not possible on embedded platforms. Also includes
-** code to buffer writes to the journal file, which can be a significant
-** performance improvement on some embedded platforms.
+** This file implements an example of a simple VFS implementation that
+** omits complex features often not required or not possible on embedded
+** platforms. Code is included to buffer writes to the journal file,
+** which can be a significant performance improvement on some embedded
+** platforms.
**
-*/
-
-/*
** OVERVIEW
**
** The code in this file implements a minimal SQLite VFS that can be
@@ -128,6 +126,7 @@
#include <unistd.h>
#include <time.h>
#include <errno.h>
+#include <fcntl.h>
/*
** Size of the write buffer used by journal files in bytes.
@@ -537,7 +536,7 @@ static int demoFullPathname(
if( zPath[0]=='/' ){
zDir[0] = '\0';
}else{
- getcwd(zDir, sizeof(zDir));
+ if( getcwd(zDir, sizeof(zDir))==0 ) return SQLITE_IOERR;
}
zDir[MAXPATHNAME] = '\0';
« no previous file with comments | « third_party/sqlite/src/src/test_config.c ('k') | third_party/sqlite/src/src/test_fs.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698