1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-10-24 09:53:10 +03:00

Fix a 'const' issue in trimFunc(). (CVS 4608)

FossilOrigin-Name: 64787d78b99a549a87bc2baeff8ae87691612b77
This commit is contained in:
danielk1977
2007-12-11 04:23:19 +00:00
parent 64c1ea60cd
commit bc67da48af
3 changed files with 12 additions and 12 deletions

View File

@@ -1,5 +1,5 @@
C Make\ssure\sthe\swindows\sdriver\sresponds\scorrectly\sto\sthe\nSQLITE_OPEN_DELETEONCLOSE\sflag.\s\sTicket\s#2829.\s(CVS\s4607)
D 2007-12-10T21:11:32
C Fix\sa\s'const'\sissue\sin\strimFunc().\s(CVS\s4608)
D 2007-12-11T04:23:20
F Makefile.arm-wince-mingw32ce-gcc ac5f7b2cef0cd850d6f755ba6ee4ab961b1fadf7
F Makefile.in 30789bf70614bad659351660d76b8e533f3340e9
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@@ -93,7 +93,7 @@ F src/date.c 49c5a6d2de6c12000905b4d36868b07d3011bbf6
F src/delete.c 034b87768c4135a22038a86a205f9d2d5f68a143
F src/experimental.c 1b2d1a6cd62ecc39610e97670332ca073c50792b
F src/expr.c 7c8e3295ddeb835ed081b8573caaf8c3fd7c9f9c
F src/func.c 5b713bbf17bc5e4daf340309666c84a65e08a32c
F src/func.c 9c87ddf907e72ac1990146ff2d68dce21d68b419
F src/hash.c 45a7005aac044b6c86bd7e49c44bc15d30006d6c
F src/hash.h 031cd9f915aff27e12262cb9eb570ac1b8326b53
F src/insert.c a090c7258f2be707cca8f0cf376142f141621241
@@ -598,7 +598,7 @@ F www/tclsqlite.tcl 8be95ee6dba05eabcd27a9d91331c803f2ce2130
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b
F www/whentouse.tcl fc46eae081251c3c181bd79c5faef8195d7991a5
P 0d9b0e6e3a8f8a66956878084085842e94c3cb2f
R c366a4cd83264cae9aaf44c2780f213e
U drh
Z b8312678fecc68786c25bce111e857ca
P 19db91fd683c465b8c8a862143a01178682da445
R 02b51d131f38d3372c7db479963e4078
U danielk1977
Z 855904ab9f628931c080d37cbbc68490

View File

@@ -1 +1 @@
19db91fd683c465b8c8a862143a01178682da445
64787d78b99a549a87bc2baeff8ae87691612b77

View File

@@ -16,7 +16,7 @@
** sqliteRegisterBuildinFunctions() found at the bottom of the file.
** All other code has file scope.
**
** $Id: func.c,v 1.179 2007/12/10 18:07:21 drh Exp $
** $Id: func.c,v 1.180 2007/12/11 04:23:20 danielk1977 Exp $
*/
#include "sqliteInt.h"
#include <ctype.h>
@@ -878,7 +878,7 @@ static void trimFunc(
int flags; /* 1: trimleft 2: trimright 3: trim */
int i; /* Loop counter */
unsigned char *aLen; /* Length of each character in zCharSet */
const unsigned char **azChar; /* Individual characters in zCharSet */
unsigned char **azChar; /* Individual characters in zCharSet */
int nChar; /* Number of characters in zCharSet */
if( sqlite3_value_type(argv[0])==SQLITE_NULL ){
@@ -893,7 +893,7 @@ static void trimFunc(
static const unsigned char *azOne[] = { (u8*)" " };
nChar = 1;
aLen = (u8*)lenOne;
azChar = azOne;
azChar = (unsigned char **)azOne;
zCharSet = 0;
}else if( (zCharSet = sqlite3_value_text(argv[1]))==0 ){
return;
@@ -909,7 +909,7 @@ static void trimFunc(
}
aLen = (unsigned char*)&azChar[nChar];
for(z=zCharSet, nChar=0; *z; nChar++){
azChar[nChar] = z;
azChar[nChar] = (unsigned char *)z;
SQLITE_SKIP_UTF8(z);
aLen[nChar] = z - azChar[nChar];
}