| Index: third_party/sqlite/src/src/loadext.c
|
| diff --git a/third_party/sqlite/src/src/loadext.c b/third_party/sqlite/src/src/loadext.c
|
| index 1fa6aa39a1c1033d2f43fc9f0ec3dea7146e621f..835b8a84ea01bffc078bc49a07d05415665b085b 100644
|
| --- a/third_party/sqlite/src/src/loadext.c
|
| +++ b/third_party/sqlite/src/src/loadext.c
|
| @@ -11,8 +11,6 @@
|
| *************************************************************************
|
| ** This file contains code used to dynamically load extensions into
|
| ** the SQLite library.
|
| -**
|
| -** $Id: loadext.c,v 1.60 2009/06/03 01:24:54 drh Exp $
|
| */
|
|
|
| #ifndef SQLITE_CORE
|
| @@ -378,13 +376,11 @@ static int sqlite3LoadExtension(
|
| handle = sqlite3OsDlOpen(pVfs, zFile);
|
| if( handle==0 ){
|
| if( pzErrMsg ){
|
| - zErrmsg = sqlite3StackAllocZero(db, nMsg);
|
| + *pzErrMsg = zErrmsg = sqlite3_malloc(nMsg);
|
| if( zErrmsg ){
|
| sqlite3_snprintf(nMsg, zErrmsg,
|
| "unable to open shared library [%s]", zFile);
|
| sqlite3OsDlError(pVfs, nMsg-1, zErrmsg);
|
| - *pzErrMsg = sqlite3DbStrDup(0, zErrmsg);
|
| - sqlite3StackFree(db, zErrmsg);
|
| }
|
| }
|
| return SQLITE_ERROR;
|
| @@ -393,13 +389,11 @@ static int sqlite3LoadExtension(
|
| sqlite3OsDlSym(pVfs, handle, zProc);
|
| if( xInit==0 ){
|
| if( pzErrMsg ){
|
| - zErrmsg = sqlite3StackAllocZero(db, nMsg);
|
| + *pzErrMsg = zErrmsg = sqlite3_malloc(nMsg);
|
| if( zErrmsg ){
|
| sqlite3_snprintf(nMsg, zErrmsg,
|
| "no entry point [%s] in shared library [%s]", zProc,zFile);
|
| sqlite3OsDlError(pVfs, nMsg-1, zErrmsg);
|
| - *pzErrMsg = sqlite3DbStrDup(0, zErrmsg);
|
| - sqlite3StackFree(db, zErrmsg);
|
| }
|
| sqlite3OsDlClose(pVfs, handle);
|
| }
|
|
|