Begin tracing memory allocations to out. */
| 1607 | |
| 1608 | /* Begin tracing memory allocations to out. */ |
| 1609 | int sqlite3MemTraceActivate(FILE *out){ |
| 1610 | int rc = SQLITE_OK; |
| 1611 | if( memtraceBase.xMalloc==0 ){ |
| 1612 | rc = sqlite3_config(SQLITE_CONFIG_GETMALLOC, &memtraceBase); |
| 1613 | if( rc==SQLITE_OK ){ |
| 1614 | rc = sqlite3_config(SQLITE_CONFIG_MALLOC, &ersaztMethods); |
| 1615 | } |
| 1616 | } |
| 1617 | memtraceOut = out; |
| 1618 | return rc; |
| 1619 | } |
| 1620 | |
| 1621 | /* Deactivate memory tracing */ |
| 1622 | int sqlite3MemTraceDeactivate(void){ |