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

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

Issue 6990047: Import SQLite 3.7.6.3. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 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/mem5.c ('k') | third_party/sqlite/src/src/mutex.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/src/memjournal.c
diff --git a/third_party/sqlite/src/src/memjournal.c b/third_party/sqlite/src/src/memjournal.c
index df770b44ed3a7a3c091bb76de5f6323e37b33eb8..3e66e215b2a84af474fa7fee9084c7ff6c3c4f6c 100644
--- a/third_party/sqlite/src/src/memjournal.c
+++ b/third_party/sqlite/src/src/memjournal.c
@@ -13,8 +13,6 @@
** This file contains code use to implement an in-memory rollback journal.
** The in-memory rollback journal is used to journal transactions for
** ":memory:" databases and when the journal_mode=MEMORY pragma is used.
-**
-** @(#) $Id: memjournal.c,v 1.12 2009/05/04 11:42:30 danielk1977 Exp $
*/
#include "sqliteInt.h"
@@ -198,11 +196,10 @@ static int memjrnlClose(sqlite3_file *pJfd){
** exists purely as a contingency, in case some malfunction in some other
** part of SQLite causes Sync to be called by mistake.
*/
-static int memjrnlSync(sqlite3_file *NotUsed, int NotUsed2){ /*NO_TEST*/
- UNUSED_PARAMETER2(NotUsed, NotUsed2); /*NO_TEST*/
- assert( 0 ); /*NO_TEST*/
- return SQLITE_OK; /*NO_TEST*/
-} /*NO_TEST*/
+static int memjrnlSync(sqlite3_file *NotUsed, int NotUsed2){
+ UNUSED_PARAMETER2(NotUsed, NotUsed2);
+ return SQLITE_OK;
+}
/*
** Query the size of the file in bytes.
@@ -216,7 +213,7 @@ static int memjrnlFileSize(sqlite3_file *pJfd, sqlite_int64 *pSize){
/*
** Table of methods for MemJournal sqlite3_file object.
*/
-static struct sqlite3_io_methods MemJournalMethods = {
+static const struct sqlite3_io_methods MemJournalMethods = {
1, /* iVersion */
memjrnlClose, /* xClose */
memjrnlRead, /* xRead */
@@ -229,7 +226,11 @@ static struct sqlite3_io_methods MemJournalMethods = {
0, /* xCheckReservedLock */
0, /* xFileControl */
0, /* xSectorSize */
- 0 /* xDeviceCharacteristics */
+ 0, /* xDeviceCharacteristics */
+ 0, /* xShmMap */
+ 0, /* xShmLock */
+ 0, /* xShmBarrier */
+ 0 /* xShmUnlock */
};
/*
@@ -239,7 +240,7 @@ void sqlite3MemJournalOpen(sqlite3_file *pJfd){
MemJournal *p = (MemJournal *)pJfd;
assert( EIGHT_BYTE_ALIGNMENT(p) );
memset(p, 0, sqlite3MemJournalSize());
- p->pMethod = &MemJournalMethods;
+ p->pMethod = (sqlite3_io_methods*)&MemJournalMethods;
}
/*
@@ -251,8 +252,7 @@ int sqlite3IsMemJournal(sqlite3_file *pJfd){
}
/*
-** Return the number of bytes required to store a MemJournal that uses vfs
-** pVfs to create the underlying on-disk files.
+** Return the number of bytes required to store a MemJournal file descriptor.
*/
int sqlite3MemJournalSize(void){
return sizeof(MemJournal);
« no previous file with comments | « third_party/sqlite/src/src/mem5.c ('k') | third_party/sqlite/src/src/mutex.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698