1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

For the mem1.c system malloc implementation, use the malloc_usable_size()

function if the HAVE_MALLOC_USABLE_SIZE macro is defined.  Update autoconf
to look for that function when configuring.

FossilOrigin-Name: 2e8ab3cedfebc33a831837792b523d1aa7cdc6b7
This commit is contained in:
drh
2011-11-09 01:53:25 +00:00
parent e5c40b18e3
commit 6a8ab6d9cb
9 changed files with 272 additions and 199 deletions

View File

@@ -37,6 +37,14 @@
** procedures use this to determine when tests should be omitted.
*/
static void set_options(Tcl_Interp *interp){
#ifdef HAVE_MALLOC_USABLE_SIZE
Tcl_SetVar2(interp, "sqlite_options", "malloc_usable_size", "1",
TCL_GLOBAL_ONLY);
#else
Tcl_SetVar2(interp, "sqlite_options", "malloc_usable_size", "0",
TCL_GLOBAL_ONLY);
#endif
#ifdef SQLITE_32BIT_ROWID
Tcl_SetVar2(interp, "sqlite_options", "rowid32", "1", TCL_GLOBAL_ONLY);
#else