mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-15 11:41:13 +03:00
Change the sqlite3_create_function() family of routines to return
SQLITE_MISUSE instead of SQLITE_ERROR if their parameters are incorrect. (CVS 6617) FossilOrigin-Name: 866f13e28c6fdb98947e1c7a89b7855bb5bbdb96
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: main.c,v 1.548 2009/05/06 19:03:14 drh Exp $
|
||||
** $Id: main.c,v 1.549 2009/05/07 13:43:49 drh Exp $
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
|
||||
@@ -931,8 +931,7 @@ int sqlite3CreateFunc(
|
||||
(!xFunc && (!xFinal && xStep)) ||
|
||||
(nArg<-1 || nArg>SQLITE_MAX_FUNCTION_ARG) ||
|
||||
(255<(nName = sqlite3Strlen30( zFunctionName))) ){
|
||||
sqlite3Error(db, SQLITE_ERROR, "bad parameters");
|
||||
return SQLITE_ERROR;
|
||||
return SQLITE_MISUSE;
|
||||
}
|
||||
|
||||
#ifndef SQLITE_OMIT_UTF16
|
||||
|
||||
Reference in New Issue
Block a user