Add some 'const' markers to static data that is really constant.
FossilOrigin-Name: e7073e23b80e7cae0c76d42f014ee9b2d40a8f2f
This commit is contained in:
parent
8b3cf82ddf
commit
558814f8c6
44
manifest
44
manifest
@ -1,8 +1,5 @@
|
||||
-----BEGIN PGP SIGNED MESSAGE-----
|
||||
Hash: SHA1
|
||||
|
||||
C The\sshared-memory\sused\sby\sWAL\son\slinux\snow\sreally\sis\sshared\smemory\sin\s/dev/shm.\nOn\sother\sunix\sflavors,\sthe\sfile\sis\sin\sa\stemporary\sdirectory\srather\sthan\sin\sthe\nsame\sdirectory\sas\sthe\sdatabase.
|
||||
D 2010-06-01T21:02:52
|
||||
C Add\ssome\s'const'\smarkers\sto\sstatic\sdata\sthat\sis\sreally\sconstant.
|
||||
D 2010-06-02T05:53:53
|
||||
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
|
||||
F Makefile.in a5cad1f8f3e021356bfcc6c77dc16f6f1952bbc3
|
||||
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
|
||||
@ -108,8 +105,8 @@ F sqlite.pc.in 42b7bf0d02e08b9e77734a47798d1a55a9e0716b
|
||||
F sqlite3.1 6be1ad09113570e1fc8dcaff84c9b0b337db5ffc
|
||||
F sqlite3.pc.in ae6f59a76e862f5c561eb32a380228a02afc3cad
|
||||
F src/alter.c a9ff6f14b3935502537e90194b66c7bc79bed317
|
||||
F src/analyze.c 8dfd781ac326496746ecdfc3e099250ed5d79be5
|
||||
F src/attach.c 7f1f760bacd9c5b6cbf6fbc3ceb159ed19ee910a
|
||||
F src/analyze.c 3457a2af126eb78f20ad239c225a2c8ed61b78b6
|
||||
F src/attach.c 47b230972b52580e3b3bd6ee69e55f3a043b615b
|
||||
F src/auth.c 523da7fb4979469955d822ff9298352d6b31de34
|
||||
F src/backup.c de9809091b3b99f69e37261c133f7f8b19f6eca6
|
||||
F src/bitvec.c 06ad2c36a9c3819c0b9cbffec7b15f58d5d834e0
|
||||
@ -117,7 +114,7 @@ F src/btmutex.c 96a12f50f7a17475155971a241d85ec5171573ff
|
||||
F src/btree.c 5934a9f5a328488cca392766bb841ff41c9083a9
|
||||
F src/btree.h dd83041eda10c17daf023257c1fc883b5f71f85a
|
||||
F src/btreeInt.h b0c87f6725b06a0aa194a6d25d54b16ce9d6e291
|
||||
F src/build.c 11100b66fb97638d2d874c1d34d8db90650bb1d7
|
||||
F src/build.c fa9bf633653e03111dc6fd406912cfb3c047bb85
|
||||
F src/callback.c 01843bdf4b0420fd28046525d150fcd9802931a9
|
||||
F src/complete.c dc1d136c0feee03c2f7550bafc0d29075e36deac
|
||||
F src/ctime.c 51553a859994d01d8bf3500747f66a890c459774
|
||||
@ -143,13 +140,13 @@ F src/mem1.c 89d4ea8d5cdd55635cbaa48ad53132af6294cbb2
|
||||
F src/mem2.c 2ee7bdacda8299b5a91cff9f7ee3e46573195c38
|
||||
F src/mem3.c 9b237d911ba9904142a804be727cc6664873f8a3
|
||||
F src/mem5.c eb7a5cb98915dd7a086fa415ce3a5a0f20d0acff
|
||||
F src/memjournal.c f3be374af30588de297dcf678925b2a4758e4135
|
||||
F src/mutex.c e2358d8f9a9021ab0bba4d511bb701e471e6e5f6
|
||||
F src/memjournal.c 2293d6a7d4c61f0b84960e17bc793b77f4b3e452
|
||||
F src/mutex.c 6949180803ff05a7d0e2b9334a95b4fb5a00e23f
|
||||
F src/mutex.h 6fde601e55fa6c3fae768783c439797ab84c87c6
|
||||
F src/mutex_noop.c 10ae943d26ba86ea92319f72adbb501a89c563e0
|
||||
F src/mutex_os2.c 20477db50cf3817c2f1cd3eb61e5c177e50231db
|
||||
F src/mutex_unix.c becb8c4e07616abf84650d3687d62a1461d5d9cd
|
||||
F src/mutex_w32.c fb1cf87c5a88b56c7df0d9ddb796ed9641046c3d
|
||||
F src/mutex_noop.c e6c3e448ac0514b27af1f8949f0347e4340f7af3
|
||||
F src/mutex_os2.c 6a62583e374ba3ac1a3fcc0da2bfdac7d3942689
|
||||
F src/mutex_unix.c cf84466b4fdd2baa0d5a10bb19f08b2abc1ce42e
|
||||
F src/mutex_w32.c 1fe0e735897be20e09dd6f53c3fb516c6b48c0eb
|
||||
F src/notify.c cbfa66a836da3a51567209636e6a94059c137930
|
||||
F src/os.c 1516984144e26734f97748f891f1a04f9e294c2e
|
||||
F src/os.h 6f604986f0ef0ca288c2330b16051ff70b431e8c
|
||||
@ -162,7 +159,7 @@ F src/pager.h 76466c3a5af56943537f68b1f16567101a0cd1d0
|
||||
F src/parse.y ace5c7a125d9f2a410e431ee3209034105045f7e
|
||||
F src/pcache.c ace8f6a5ecd4711cc66a1b23053be7109bd437cf
|
||||
F src/pcache.h c683390d50f856d4cd8e24342ae62027d1bb6050
|
||||
F src/pcache1.c 6dc1871ce8ead9187161c370a58cd06c84221f76
|
||||
F src/pcache1.c 3a7c28f46a61b43ff0b5c087a7983c154f4b264c
|
||||
F src/pragma.c 423865323a4074f1e0d4ab02af0be014653e8863
|
||||
F src/prepare.c fd1398cb1da54385ba5bd68d93928f10d10a1d9c
|
||||
F src/printf.c 5f5b65a83e63f2096a541a340722a509fa0240a7
|
||||
@ -173,7 +170,7 @@ F src/select.c c03d8a0565febcde8c6a12c5d77d065fddae889b
|
||||
F src/shell.c fd4ccdb37c3b68de0623eb938a649e0990710714
|
||||
F src/sqlite.h.in 4f72e39f1edeccaf2a5913483bce2f704492b892
|
||||
F src/sqlite3ext.h 69dfb8116af51b84a029cddb3b35062354270c89
|
||||
F src/sqliteInt.h c1ca9bed7c963343f90edaf0ec31b8ff4b43fb01
|
||||
F src/sqliteInt.h 4e26920ede6da1b6f154251fb4f89f65f78979e0
|
||||
F src/sqliteLimit.h 196e2f83c3b444c4548fc1874f52f84fdbda40f3
|
||||
F src/status.c 4df6fe7dce2d256130b905847c6c60055882bdbe
|
||||
F src/table.c 2cd62736f845d82200acfa1287e33feb3c15d62e
|
||||
@ -818,14 +815,7 @@ F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
|
||||
F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
|
||||
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
|
||||
F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
|
||||
P 716d99f3929b466c7a17190e0f18de8ab0e7f1fa
|
||||
R b3414260e40f837bf1c8d956dc6a26ad
|
||||
U drh
|
||||
Z 80c5ba01de50121a690a7f5cd9c5e6cc
|
||||
-----BEGIN PGP SIGNATURE-----
|
||||
Version: GnuPG v1.4.6 (GNU/Linux)
|
||||
|
||||
iD8DBQFMBXV/oxKgR168RlERAimSAJ4rYYH4hdiefDukk1w3PgpCHNzTdQCfanYl
|
||||
zzhyiYRjebOZPSJO3xolVfs=
|
||||
=lQ6P
|
||||
-----END PGP SIGNATURE-----
|
||||
P fc18c4aadb908c3b6f9b6481a2efca6a0daadc64
|
||||
R 5ffcfe6f9fb26db002e380fdcd57427f
|
||||
U dan
|
||||
Z bd5e7f649e2a59b30633343e7bfa6f7f
|
||||
|
@ -1 +1 @@
|
||||
fc18c4aadb908c3b6f9b6481a2efca6a0daadc64
|
||||
e7073e23b80e7cae0c76d42f014ee9b2d40a8f2f
|
@ -36,7 +36,7 @@ static void openStatTable(
|
||||
int iStatCur, /* Open the sqlite_stat1 table on this cursor */
|
||||
const char *zWhere /* Delete entries associated with this table */
|
||||
){
|
||||
static struct {
|
||||
static const struct {
|
||||
const char *zName;
|
||||
const char *zCols;
|
||||
} aTable[] = {
|
||||
|
@ -289,7 +289,7 @@ detach_error:
|
||||
static void codeAttach(
|
||||
Parse *pParse, /* The parser context */
|
||||
int type, /* Either SQLITE_ATTACH or SQLITE_DETACH */
|
||||
FuncDef *pFunc, /* FuncDef wrapper for detachFunc() or attachFunc() */
|
||||
FuncDef const *pFunc,/* FuncDef wrapper for detachFunc() or attachFunc() */
|
||||
Expr *pAuthArg, /* Expression to pass to authorization callback */
|
||||
Expr *pFilename, /* Name of database file */
|
||||
Expr *pDbname, /* Name of the database to use internally */
|
||||
@ -370,7 +370,7 @@ attach_end:
|
||||
** DETACH pDbname
|
||||
*/
|
||||
void sqlite3Detach(Parse *pParse, Expr *pDbname){
|
||||
static FuncDef detach_func = {
|
||||
static const FuncDef detach_func = {
|
||||
1, /* nArg */
|
||||
SQLITE_UTF8, /* iPrefEnc */
|
||||
0, /* flags */
|
||||
@ -391,7 +391,7 @@ void sqlite3Detach(Parse *pParse, Expr *pDbname){
|
||||
** ATTACH p AS pDbname KEY pKey
|
||||
*/
|
||||
void sqlite3Attach(Parse *pParse, Expr *p, Expr *pDbname, Expr *pKey){
|
||||
static FuncDef attach_func = {
|
||||
static const FuncDef attach_func = {
|
||||
3, /* nArg */
|
||||
SQLITE_UTF8, /* iPrefEnc */
|
||||
0, /* flags */
|
||||
|
@ -3382,7 +3382,7 @@ void sqlite3Savepoint(Parse *pParse, int op, Token *pName){
|
||||
if( zName ){
|
||||
Vdbe *v = sqlite3GetVdbe(pParse);
|
||||
#ifndef SQLITE_OMIT_AUTHORIZATION
|
||||
static const char *az[] = { "BEGIN", "RELEASE", "ROLLBACK" };
|
||||
static const char * const az[] = { "BEGIN", "RELEASE", "ROLLBACK" };
|
||||
assert( !SAVEPOINT_BEGIN && SAVEPOINT_RELEASE==1 && SAVEPOINT_ROLLBACK==2 );
|
||||
#endif
|
||||
if( !v || sqlite3AuthCheck(pParse, SQLITE_SAVEPOINT, az[op], zName, 0) ){
|
||||
|
@ -213,7 +213,7 @@ static int memjrnlFileSize(sqlite3_file *pJfd, sqlite_int64 *pSize){
|
||||
/*
|
||||
** Table of methods for MemJournal sqlite3_file object.
|
||||
*/
|
||||
static struct sqlite3_io_methods MemJournalMethods = {
|
||||
static const struct sqlite3_io_methods MemJournalMethods = {
|
||||
1, /* iVersion */
|
||||
memjrnlClose, /* xClose */
|
||||
memjrnlRead, /* xRead */
|
||||
|
@ -37,7 +37,7 @@ int sqlite3MutexInit(void){
|
||||
** sqlite3_initialize() being called. This block copies pointers to
|
||||
** the default implementation into the sqlite3GlobalConfig structure.
|
||||
*/
|
||||
sqlite3_mutex_methods *pFrom;
|
||||
sqlite3_mutex_methods const *pFrom;
|
||||
sqlite3_mutex_methods *pTo = &sqlite3GlobalConfig.mutex;
|
||||
|
||||
if( sqlite3GlobalConfig.bCoreMutex ){
|
||||
|
@ -43,8 +43,8 @@ static void noopMutexEnter(sqlite3_mutex *p){ return; }
|
||||
static int noopMutexTry(sqlite3_mutex *p){ return SQLITE_OK; }
|
||||
static void noopMutexLeave(sqlite3_mutex *p){ return; }
|
||||
|
||||
sqlite3_mutex_methods *sqlite3NoopMutex(void){
|
||||
static sqlite3_mutex_methods sMutex = {
|
||||
sqlite3_mutex_methods const *sqlite3NoopMutex(void){
|
||||
static const sqlite3_mutex_methods sMutex = {
|
||||
noopMutexInit,
|
||||
noopMutexEnd,
|
||||
noopMutexAlloc,
|
||||
@ -170,8 +170,8 @@ static void debugMutexLeave(sqlite3_mutex *pX){
|
||||
assert( p->id==SQLITE_MUTEX_RECURSIVE || debugMutexNotheld(pX) );
|
||||
}
|
||||
|
||||
sqlite3_mutex_methods *sqlite3NoopMutex(void){
|
||||
static sqlite3_mutex_methods sMutex = {
|
||||
sqlite3_mutex_methods const *sqlite3NoopMutex(void){
|
||||
static const sqlite3_mutex_methods sMutex = {
|
||||
debugMutexInit,
|
||||
debugMutexEnd,
|
||||
debugMutexAlloc,
|
||||
@ -193,7 +193,7 @@ sqlite3_mutex_methods *sqlite3NoopMutex(void){
|
||||
** is used regardless of the run-time threadsafety setting.
|
||||
*/
|
||||
#ifdef SQLITE_MUTEX_NOOP
|
||||
sqlite3_mutex_methods *sqlite3DefaultMutex(void){
|
||||
sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
|
||||
return sqliteNoopMutex();
|
||||
}
|
||||
#endif /* SQLITE_MUTEX_NOOP */
|
||||
|
@ -251,8 +251,8 @@ static void os2MutexLeave(sqlite3_mutex *p){
|
||||
DosReleaseMutexSem(p->mutex);
|
||||
}
|
||||
|
||||
sqlite3_mutex_methods *sqlite3DefaultMutex(void){
|
||||
static sqlite3_mutex_methods sMutex = {
|
||||
sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
|
||||
static const sqlite3_mutex_methods sMutex = {
|
||||
os2MutexInit,
|
||||
os2MutexEnd,
|
||||
os2MutexAlloc,
|
||||
|
@ -325,8 +325,8 @@ static void pthreadMutexLeave(sqlite3_mutex *p){
|
||||
#endif
|
||||
}
|
||||
|
||||
sqlite3_mutex_methods *sqlite3DefaultMutex(void){
|
||||
static sqlite3_mutex_methods sMutex = {
|
||||
sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
|
||||
static const sqlite3_mutex_methods sMutex = {
|
||||
pthreadMutexInit,
|
||||
pthreadMutexEnd,
|
||||
pthreadMutexAlloc,
|
||||
|
@ -307,8 +307,8 @@ static void winMutexLeave(sqlite3_mutex *p){
|
||||
#endif
|
||||
}
|
||||
|
||||
sqlite3_mutex_methods *sqlite3DefaultMutex(void){
|
||||
static sqlite3_mutex_methods sMutex = {
|
||||
sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
|
||||
static const sqlite3_mutex_methods sMutex = {
|
||||
winMutexInit,
|
||||
winMutexEnd,
|
||||
winMutexAlloc,
|
||||
|
@ -716,7 +716,7 @@ static void pcache1Destroy(sqlite3_pcache *p){
|
||||
** already provided an alternative.
|
||||
*/
|
||||
void sqlite3PCacheSetDefault(void){
|
||||
static sqlite3_pcache_methods defaultMethods = {
|
||||
static const sqlite3_pcache_methods defaultMethods = {
|
||||
0, /* pArg */
|
||||
pcache1Init, /* xInit */
|
||||
pcache1Shutdown, /* xShutdown */
|
||||
|
@ -2536,8 +2536,8 @@ const sqlite3_mem_methods *sqlite3MemGetMemsys5(void);
|
||||
|
||||
|
||||
#ifndef SQLITE_MUTEX_OMIT
|
||||
sqlite3_mutex_methods *sqlite3DefaultMutex(void);
|
||||
sqlite3_mutex_methods *sqlite3NoopMutex(void);
|
||||
sqlite3_mutex_methods const *sqlite3DefaultMutex(void);
|
||||
sqlite3_mutex_methods const *sqlite3NoopMutex(void);
|
||||
sqlite3_mutex *sqlite3MutexAlloc(int);
|
||||
int sqlite3MutexInit(void);
|
||||
int sqlite3MutexEnd(void);
|
||||
|
Loading…
x
Reference in New Issue
Block a user