mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Publish APIs sqlite3_malloc() and sqlite3_realloc() that use the OS-layer
memory allocator. Convert sqlite3_free() and sqlite3_mprintf() to also use the OS-layer memory allocator. (CVS 3298) FossilOrigin-Name: 85a66a25e97471d3c459c8da6a96990b0537dc7d
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
** other files are for internal use by SQLite and should not be
|
||||
** accessed by users of the library.
|
||||
**
|
||||
** $Id: legacy.c,v 1.14 2006/03/06 20:55:46 drh Exp $
|
||||
** $Id: legacy.c,v 1.15 2006/06/26 21:35:45 drh Exp $
|
||||
*/
|
||||
|
||||
#include "sqliteInt.h"
|
||||
@@ -123,7 +123,7 @@ exec_out:
|
||||
|
||||
rc = sqlite3ApiExit(0, rc);
|
||||
if( rc!=SQLITE_OK && rc==sqlite3_errcode(db) && pzErrMsg ){
|
||||
*pzErrMsg = malloc(1+strlen(sqlite3_errmsg(db)));
|
||||
*pzErrMsg = sqlite3_malloc(1+strlen(sqlite3_errmsg(db)));
|
||||
if( *pzErrMsg ){
|
||||
strcpy(*pzErrMsg, sqlite3_errmsg(db));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user