mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
First attempt at getting the build to work with Tcl 9.0.
FossilOrigin-Name: 6e5bb48a74d63fb8c30528f0005d1763cd2dbb882abf86baf1565721e6bfcf84
This commit is contained in:
12
src/test5.c
12
src/test5.c
@@ -17,11 +17,7 @@
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
#include "vdbeInt.h"
|
||||
#if defined(INCLUDE_SQLITE_TCL_H)
|
||||
# include "sqlite_tcl.h"
|
||||
#else
|
||||
# include "tcl.h"
|
||||
#endif
|
||||
#include "tclsqlite.h"
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
@@ -36,7 +32,7 @@ static int SQLITE_TCLAPI binarize(
|
||||
int objc,
|
||||
Tcl_Obj *CONST objv[]
|
||||
){
|
||||
int len;
|
||||
Tcl_Size len;
|
||||
char *bytes;
|
||||
Tcl_Obj *pRet;
|
||||
assert(objc==2);
|
||||
@@ -133,7 +129,7 @@ static int SQLITE_TCLAPI test_translate(
|
||||
sqlite3_value *pVal;
|
||||
|
||||
char *z;
|
||||
int len;
|
||||
Tcl_Size len;
|
||||
void (*xDel)(void *p) = SQLITE_STATIC;
|
||||
|
||||
if( objc!=4 && objc!=5 ){
|
||||
@@ -164,7 +160,7 @@ static int SQLITE_TCLAPI test_translate(
|
||||
z = (char*)Tcl_GetByteArrayFromObj(objv[1], &len);
|
||||
if( objc==5 ){
|
||||
char *zTmp = z;
|
||||
z = sqlite3_malloc(len);
|
||||
z = sqlite3_malloc64(len);
|
||||
memcpy(z, zTmp, len);
|
||||
}
|
||||
sqlite3ValueSetStr(pVal, -1, z, enc_from, xDel);
|
||||
|
Reference in New Issue
Block a user