mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
Avoid unnecessary OOM detection warnings in a debugging routine.
FossilOrigin-Name: 395f8ea790e6e295800fa8927f0585b2419b9521ef4fd591d51d2a48db2a90c4
This commit is contained in:
@@ -123,9 +123,12 @@ int sqlite3_enable_shared_cache(int enable){
|
||||
*/
|
||||
#ifdef SQLITE_DEBUG
|
||||
int corruptPageError(int lineno, MemPage *p){
|
||||
char *zMsg = sqlite3_mprintf("database corruption page %d of %s",
|
||||
char *zMsg;
|
||||
sqlite3BeginBenignMalloc();
|
||||
zMsg = sqlite3_mprintf("database corruption page %d of %s",
|
||||
(int)p->pgno, sqlite3PagerFilename(p->pBt->pPager, 0)
|
||||
);
|
||||
sqlite3EndBenignMalloc();
|
||||
if( zMsg ){
|
||||
sqlite3ReportError(SQLITE_CORRUPT, lineno, zMsg);
|
||||
}
|
||||
|
Reference in New Issue
Block a user