Thanks to visit codestin.com
Credit goes to chromium.googlesource.com
Sign in
chromium
/
external
/
github.com
/
sqlite
/
sqlite
/
HEAD
/
src
/
backup.c
3115b36
Fix a segfault that could occur if a non-empty in-memory database was the destination of a backup operation from a database with a smaller page size.
by dan
· 2 years, 3 months ago
92ecf30
Fix an obscure problem in sqlite3_backup_init() caused by
by drh
· 3 years, 6 months ago
c692df2
Make it so that any Parse object is always linked into the database conenction
by drh
· 3 years, 6 months ago
99744fa
Add support for the sqlite3_txn_state() interface.
by drh
· 5 years ago
e937df8
Fix the handling of reserve-bytes so that the maximum value of 255 can be used.
by drh
· 5 years ago
b48c0d5
Simplify the code by removing the unsupported and undocumented
by drh
· 5 years ago
55f66b3
Add new assert() statements in an attempt to help static analyzers avoid
by drh
· 6 years ago
bc8b231
Fix harmless compiler warning seen with MSVC.
by mistachkin
· 6 years ago
bb2d9b1
Change sqlite3BtreeBeginTrans() to return the BTREE_SCHEMA_COOKIE, for a
by drh
· 7 years ago
cb43a93
Allocate Parse objects off of the stack where appropriate for a substantial
by drh
· 9 years ago
76729ed
Correctly detect an OOM occurring in the setDestPgsz() subroutine of backup.
by drh
· 9 years ago
033564c
Within a backup operation, ensure that a read-transaction is opened on the source database before its page size is read. This ensures the page-size used to write to the backup database is the same as its actual page-size, which is important for ZipVFS databases.
by dan
· 9 years ago
43c1ce3
Undo commit [f250166bb]. It is required to handle IO and other errors that occur within a VACUUM of a Zipvfs database.
by dan
· 9 years ago
d20b2a4
Remove the sqlite3PagerClearCache() routine, which does not accomplish anything
by drh
· 9 years ago
fad3039
Enhance ability to debug out-of-memory errors.
by mistachkin
· 9 years ago
9584f58
Rename the sqlite3PagerAcquire() function to sqlite3PagerGet(). The former
by drh
· 10 years ago
58cb6db
Take care that the number of reserved bits per page is consistent between
by drh
· 10 years ago
14681b7
Avoid create a stack from in sqlite3BackupUpdate() in the common case where
by drh
· 10 years ago
ad0961b
Keep track of the optimal number of reserved bytes (by looking at reserve
by drh
· 10 years ago
fad0199
Have calls to sqlite3_backup_init() fail if there is already a read or read-write transaction open on the destination database.
by dan
· 11 years ago
47b7fc7
Experimental changes that permit read operations to continue after a
by drh
· 11 years ago
read-after-rollback
9ca9573
Add the SQLITE_ENABLE_API_ARMOR compile-time option. This is a work in
by drh
· 11 years ago
13f40da
Split the sqlite3Error() routine into sqlite3Error() and
by drh
· 11 years ago
a3cc007
Simplication and optimization of error message handling.
by drh
· 12 years ago
999cd08
Modify the way some internal file-controls are invoked. In order to support multi-file transactions in the zipvfs extension.
by dan
· 12 years ago
f30a969
Rework the logic that factors constant expressions out of inner loops, making
by drh
· 12 years ago
b00fc3b
Simplify the btreeGetPage() routine so that it uses a single flag parameter
by drh
· 12 years ago
e1e2e9a
Make the MIN() and MAX() macros available in sqliteInt.h. Add TUNING
by drh
· 12 years ago
7e36962
Make use of xFetch, if it is available when doing a VACUUM or a backup.
by drh
· 12 years ago
f23da96
Replace the sqlite3_io_methods.xMremap interface with sqlite3_io_methods.xFetch and xUnfetch.
by dan
· 12 years ago
aa1d67b
Fix a case where the mapped part of a database file may be written during a backup operation.
by dan
· 12 years ago
896f99e
Catch a dropped error code in backup.c.
by dan
· 12 years ago
bc1a3c6
If a rollback mode transaction reduces the size of the database file, avoid actually truncating the file until after the transaction has been committed (but before the db has been unlocked). This means pages that are removed from the database by truncating the file need not be journalled.
by dan
· 12 years ago
5cc3bea
Ensure the database size field in the db header of a backup database is set correctly. Fix for [0cfd98ee201].
by dan
· 13 years ago
b483eba
Ensure that when the source of a backup is a database that is zero bytes in size, the final destination database consists of at least one page. Truncating it to zero bytes is equivalent to zeroing the schema cookie and change counter, which can cause problems for existing clients.
by dan
· 13 years ago
0094f37
Avoid calling sqlite3BtreeEnter() in a corner case where the corresponding database handle mutex (sqlite3.mutex) may not be held. This prevents a potential deadlock or crash that can occur if the backup API, shared-cache mode and SQLITE_HAVE_CODEC are all in use.
by dan
· 13 years ago
6809c96
Replace a few sqlite3_malloc()+memset() sequences with calls to sqlite3MallocZero().
by dan
· 13 years ago
ed68801
Add the sqlite3_close_v2() interface (from the deferred-close branch) that
by drh
· 13 years ago
4245c40
The sqlite3_close() interface returns SQLITE_OK even if there are outstanding
by drh
· 13 years ago
81028a4
The former sqlite3ResetInternalSchema() routine was really two different
by drh
· 13 years ago
0f198a7
Change the ROLLBACK command so that pending statements to not block it. The
by drh
· 13 years ago
2bfe5b3
Check the return code from sqlite3OsFileControl() in sqlite3BtreeCopyFile()
by drh
· 14 years ago
92c45cf
Remove the BenignMalloc() from around the call to FCNTL_OVERWRITE. Add
by drh
· 14 years ago
c916634
Combine various boolean variables in the BtShared structure into a single
by drh
· 14 years ago
23a3de3
Add calls to the BenignMalloc() functions around the SQLITE_FCNTL_OVERWRITE call in backup.c.
by dan
· 14 years ago
1a83bc5
If an error occurs while writing to the database file during a VACUUM, discard the contents of the in-memory cache. This is required as if the database is a zipvfs database, the contents of the cache may be inconsistent with respect to the database as stored on disk.
by dan
· 14 years ago
30ddce6
Added the tool/warnings-clang.sh script. Changes so that there are no
by drh
· 14 years ago
c5f20a0
Add the SQLITE_FCNTL_OVERWRITE file-control. Used by SQLite to indicate to the OS layer that the current transaction will overwrite the entire file.
by dan
· 14 years ago
c5dbffe
Reorder some of the branches in backup.c in order to make the code
by drh
· 14 years ago
4b27040
Replace an assert() that a condition may not occur in backup.c with code to handle that condition, which can occur.
by dan
· 14 years ago
06199d8
When copying a rollback mode database over a WAL database using the backup API, leave the destination database in WAL mode (instead of switching it to rollback mode). Fix for [af95b8c609].
by dan
· 14 years ago
806ebcb
Remove an always-true conditional. Replace it with an assert().
by drh
· 14 years ago
2b89fbc
Do not do a backup if the number of reserved bytes in the source and
by drh
· 14 years ago
c7792fa
Begin a series of changes designed to reduce the scope and frequency of
by drh
· 14 years ago
60939d0
Fix a problem whereby following an IO error in CommitPhaseTwo() of a multi-file transaction the b-tree layer could be left in TRANS_WRITE state, causing problems later on.
by dan
· 14 years ago
4d26d58
Add a missing call to sqlite3PagerSync() removed by [ce552d975] to the backup code.
by dan
· 14 years ago
c6aed54
On a backup from a smaller to a larger page size, do not begin committing
by drh
· 15 years ago
ca94d8b
Change the page size of the destination database in a backup, if it is
by drh
· 15 years ago
9f129f4
Add evidence mark comments to source code. Add additional information to the
by drh
· 15 years ago
871919b
Do not allow a backup to change the page size if a codec is in use.
by drh
· 15 years ago
ba3cbf3
Add coverage test cases. Have sqlite3_backup_step() transform SQLITE_IOERR_NOMEM to SQLITE_NOMEM before returning.
by dan
· 15 years ago
0b9b430
Refactor and simplify the logic used to change journalmode.
by drh
· 15 years ago
5c10f77
Do not compare page sizes on source and destination of backup until
by drh
· 15 years ago
3289c5e
Prohibit backup if the destination is using WAL and has a different page
by drh
· 15 years ago
b129915
Continuing refinements to the filesize-in-header enhancement.
by drh
· 15 years ago
a756466
Log all error messages if logging is enabled.
by drh
· 15 years ago
c81c11f
Remove the obsolete "$Id:$" RCS identifier strings from the source code.
by drh
· 16 years ago
f25cd71
Fix the backup logic so that it detects a failure to sqlite3BtreeUpdateMeta()
by drh
· 16 years ago
602b466
Cause opening a transaction on a sharable b-tree module automatically obtain a read-lock on page 1. This means there is no way for sqlite3BtreeGetMeta() to fail. (CVS 6836)
by danielk1977
· 16 years ago
0d19f7a
Define a set of constants to use as the "index" argument to sqlite3BtreeGetMeta and UpdateMeta. This makes some parts of the code easier to follow. (CVS 6709)
by danielk1977
· 16 years ago
e98c904
Further reductions in the amount of stack space required. (CVS 6707)
by drh
· 16 years ago
dcd7db5
Change the sqlite3_backup_finish() interface so that calling it with
by drh
· 16 years ago
e70f4f6
When locking a database file, check if any backup objects need to be restarted even if the page cache is empty. Ticket #3858. (CVS 6632)
by danielk1977
· 16 years ago
404ca07
Add the sqlite3_unlock_notify() API. (CVS 6348)
by danielk1977
· 16 years ago
65ad7d2
Changes to remove some compiler warnings from MSVC. (CVS 6294)
by shane
· 16 years ago
38aec8d
Fix a compiler warning in backup.c. (CVS 6293)
by drh
· 16 years ago
f2a79f2
Fix some edge cases with backing up databases that are exactly PENDING_BYTE bytes in size, or just slightly larger. (CVS 6288)
by danielk1977
· 16 years ago
3d0cbc3
Fix a problem in backup.c causing OsTruncate() to be called with an argument larger than the current file-size. (CVS 6271)
by danielk1977
· 16 years ago
03ab035
Changes to the backup API: (1) if a negative number is passed as the second argument to backup_step(), this is interpreted as "copy all remaining pages" and (2) if backup_finish() is called after backup_step() fails with a BUSY or LOCKED error, then this error is also returned by backup_finish() (same handling as for other errors encountered by backup_step()). (CVS 6266)
by danielk1977
· 16 years ago
b309bec
Simplify wording of backup API error message. Decapitalize some other
by drh
· 16 years ago
eef1eb0
The sqlite3_backup_init() interface must lock the destination in case it
by drh
· 16 years ago
63207ab
Remove compiler warnings under MSVC. (CVS 6249)
by shane
· 16 years ago
d3a5c50
Correction to check-ins (6246) and (6247): The backup object might not
by drh
· 16 years ago
6231286
A backup must clear the internal schema of the destination database so
by drh
· 16 years ago
662c58c
Must hold mutex on the destination during backups. Add documentation to
by drh
· 16 years ago
0410302
Commit first version of the 'backup' feature. (CVS 6241)
by danielk1977
· 16 years ago