mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
Change the definition of SQLITE_CONFIG_PAGECACHE and
SQLITE_CONFIG_SCRATCH to omit the magic "+4" in the buffer size calculation. (CVS 5512) FossilOrigin-Name: e7ed0fe640a39053009eac52a7f055b121750e57
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
** This file contains code used to implement test interfaces to the
|
||||
** memory allocation subsystem.
|
||||
**
|
||||
** $Id: test_malloc.c,v 1.43 2008/07/29 14:29:07 drh Exp $
|
||||
** $Id: test_malloc.c,v 1.44 2008/07/31 17:16:05 drh Exp $
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
#include "tcl.h"
|
||||
@@ -886,7 +886,7 @@ static int test_config_scratch(
|
||||
buf = 0;
|
||||
rc = sqlite3_config(SQLITE_CONFIG_SCRATCH, 0, 0, 0);
|
||||
}else{
|
||||
buf = malloc( (sz+4)*N );
|
||||
buf = malloc( sz*N );
|
||||
rc = sqlite3_config(SQLITE_CONFIG_SCRATCH, buf, sz, N);
|
||||
}
|
||||
pResult = Tcl_NewObj();
|
||||
@@ -926,7 +926,7 @@ static int test_config_pagecache(
|
||||
buf = 0;
|
||||
rc = sqlite3_config(SQLITE_CONFIG_PAGECACHE, 0, 0, 0);
|
||||
}else{
|
||||
buf = malloc( (sz+4)*N );
|
||||
buf = malloc( sz*N );
|
||||
rc = sqlite3_config(SQLITE_CONFIG_PAGECACHE, buf, sz, N);
|
||||
}
|
||||
pResult = Tcl_NewObj();
|
||||
|
Reference in New Issue
Block a user