Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | All filenames are now URI capable. There is no provision for disabling URI filenames. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
735870610b47d771f59af4ea8bc2fd85 |
User & Date: | drh 2012-04-21 13:00:50.593 |
Context
2012-04-21
| ||
13:18 | Remove the alternative pcache mechanism. check-in: bf89aa0f37 user: drh tags: trunk | |
13:00 | All filenames are now URI capable. There is no provision for disabling URI filenames. check-in: 735870610b user: drh tags: trunk | |
12:49 | Remove the last traces of shared cache mode. check-in: 27e0994174 user: drh tags: trunk | |
Changes
Changes to src/global.c.
︙ | ︙ | |||
125 126 127 128 129 130 131 | 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* e0..e7 ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* e8..ef ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* f0..f7 ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40 /* f8..ff ........ */ }; #endif | < < < < < | 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 | 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* e0..e7 ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* e8..ef ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, /* f0..f7 ........ */ 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40 /* f8..ff ........ */ }; #endif /* ** The following singleton contains the global configuration for ** the SQLite library. */ SQLITE_WSD struct Sqlite3Config sqlite4Config = { SQLITE_DEFAULT_MEMSTATUS, /* bMemstat */ 1, /* bCoreMutex */ SQLITE_THREADSAFE==1, /* bFullMutex */ 0x7ffffffe, /* mxStrlen */ 128, /* szLookaside */ 500, /* nLookaside */ {0,0,0,0,0,0,0,0}, /* m */ {0,0,0,0,0,0,0,0,0}, /* mutex */ {0,0,0,0,0,0,0,0,0,0,0,0,0},/* pcache2 */ (void*)0, /* pHeap */ |
︙ | ︙ |
Changes to src/main.c.
︙ | ︙ | |||
405 406 407 408 409 410 411 | */ typedef void(*LOGFUNC_t)(void*,int,const char*); sqlite4GlobalConfig.xLog = va_arg(ap, LOGFUNC_t); sqlite4GlobalConfig.pLogArg = va_arg(ap, void*); break; } | < < < < < | 405 406 407 408 409 410 411 412 413 414 415 416 417 418 | */ typedef void(*LOGFUNC_t)(void*,int,const char*); sqlite4GlobalConfig.xLog = va_arg(ap, LOGFUNC_t); sqlite4GlobalConfig.pLogArg = va_arg(ap, void*); break; } default: { rc = SQLITE_ERROR; break; } } va_end(ap); return rc; |
︙ | ︙ | |||
1659 1660 1661 1662 1663 1664 1665 | const char *zVfs = zDefaultVfs; char *zFile; char c; int nUri = sqlite4Strlen30(zUri); assert( *pzErrMsg==0 ); | < | < < < < < | 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 | const char *zVfs = zDefaultVfs; char *zFile; char c; int nUri = sqlite4Strlen30(zUri); assert( *pzErrMsg==0 ); if( nUri>=5 && memcmp(zUri, "file:", 5)==0 ){ char *zOpt; int eState; /* Parser state when parsing URI */ int iIn; /* Input character index */ int iOut = 0; /* Output character index */ int nByte = nUri+2; /* Bytes of space to allocate */ for(iIn=0; iIn<nUri; iIn++) nByte += (zUri[iIn]=='&'); zFile = sqlite4_malloc(nByte); if( !zFile ) return SQLITE_NOMEM; /* Discard the scheme and authority segments of the URI. */ if( zUri[5]=='/' && zUri[6]=='/' ){ iIn = 7; |
︙ | ︙ |
Changes to src/shell.c.
︙ | ︙ | |||
2609 2610 2611 2612 2613 2614 2615 | ** Initialize the state information in data */ static void main_init(struct callback_data *data) { memset(data, 0, sizeof(*data)); data->mode = MODE_List; memcpy(data->separator,"|", 2); data->showHeader = 0; | < | 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 | ** Initialize the state information in data */ static void main_init(struct callback_data *data) { memset(data, 0, sizeof(*data)); data->mode = MODE_List; memcpy(data->separator,"|", 2); data->showHeader = 0; sqlite4_config(SQLITE_CONFIG_LOG, shellLog, data); sqlite4_snprintf(sizeof(mainPrompt), mainPrompt,"sqlite> "); sqlite4_snprintf(sizeof(continuePrompt), continuePrompt," ...> "); sqlite4_config(SQLITE_CONFIG_SINGLETHREAD); } int main(int argc, char **argv){ |
︙ | ︙ |
Changes to src/sqlite.h.in.
︙ | ︙ | |||
1471 1472 1473 1474 1475 1476 1477 | ** [extended result code]. ^The third parameter passed to the logger is ** log message after formatting via [sqlite4_snprintf()]. ** The SQLite logging interface is not reentrant; the logger function ** supplied by the application must not invoke any SQLite interface. ** In a multi-threaded application, the application-defined logger ** function must be threadsafe. </dd> ** | < < < < < < < < < < < < < | 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 | ** [extended result code]. ^The third parameter passed to the logger is ** log message after formatting via [sqlite4_snprintf()]. ** The SQLite logging interface is not reentrant; the logger function ** supplied by the application must not invoke any SQLite interface. ** In a multi-threaded application, the application-defined logger ** function must be threadsafe. </dd> ** ** [[SQLITE_CONFIG_PCACHE]] [[SQLITE_CONFIG_GETPCACHE]] ** <dt>SQLITE_CONFIG_PCACHE and SQLITE_CONFNIG_GETPCACHE ** <dd> These options are obsolete and should not be used by new code. ** They are retained for backwards compatibility but are now no-ops. ** </dl> */ #define SQLITE_CONFIG_SINGLETHREAD 1 /* nil */ |
︙ | ︙ | |||
1506 1507 1508 1509 1510 1511 1512 | #define SQLITE_CONFIG_MUTEX 10 /* sqlite4_mutex_methods* */ #define SQLITE_CONFIG_GETMUTEX 11 /* sqlite4_mutex_methods* */ /* previously SQLITE_CONFIG_CHUNKALLOC 12 which is now unused. */ #define SQLITE_CONFIG_LOOKASIDE 13 /* int int */ #define SQLITE_CONFIG_PCACHE 14 /* no-op */ #define SQLITE_CONFIG_GETPCACHE 15 /* no-op */ #define SQLITE_CONFIG_LOG 16 /* xFunc, void* */ | < | 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 | #define SQLITE_CONFIG_MUTEX 10 /* sqlite4_mutex_methods* */ #define SQLITE_CONFIG_GETMUTEX 11 /* sqlite4_mutex_methods* */ /* previously SQLITE_CONFIG_CHUNKALLOC 12 which is now unused. */ #define SQLITE_CONFIG_LOOKASIDE 13 /* int int */ #define SQLITE_CONFIG_PCACHE 14 /* no-op */ #define SQLITE_CONFIG_GETPCACHE 15 /* no-op */ #define SQLITE_CONFIG_LOG 16 /* xFunc, void* */ #define SQLITE_CONFIG_PCACHE2 18 /* sqlite4_pcache_methods2* */ #define SQLITE_CONFIG_GETPCACHE2 19 /* sqlite4_pcache_methods2* */ #define SQLITE_CONFIG_SET_KVFACTORY 20 /* int(*)(KVStore**,const char*,u32) */ #define SQLITE_CONFIG_GET_KVFACTORY 21 /* int(**)(KVStore**,const char*,u32) */ /* |
︙ | ︙ | |||
2376 2377 2378 2379 2380 2381 2382 | ** ** ^If the filename is an empty string, then a private, temporary ** on-disk database will be created. ^This private database will be ** automatically deleted as soon as the database connection is closed. ** ** [[URI filenames in sqlite4_open()]] <h3>URI Filenames</h3> ** | | | < < < < < < < < < | 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 | ** ** ^If the filename is an empty string, then a private, temporary ** on-disk database will be created. ^This private database will be ** automatically deleted as soon as the database connection is closed. ** ** [[URI filenames in sqlite4_open()]] <h3>URI Filenames</h3> ** ** ^If the filename argument ** begins with "file:", then the filename is interpreted as a URI. ** URI filenames are parsed according to RFC 3986. ^If the URI contains an ** authority, then it must be either an empty string or the string ** "localhost". ^If the authority is not an empty string or "localhost", an ** error is returned to the caller. ^The fragment component of a URI, if ** present, is ignored. ** ** ^SQLite uses the path component of the URI as the name of the disk file |
︙ | ︙ |
Changes to src/sqliteInt.h.
︙ | ︙ | |||
2431 2432 2433 2434 2435 2436 2437 | ** ** This structure also contains some state information. */ struct Sqlite3Config { int bMemstat; /* True to enable memory status */ int bCoreMutex; /* True to enable core mutexing */ int bFullMutex; /* True to enable full mutexing */ | < | 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 | ** ** This structure also contains some state information. */ struct Sqlite3Config { int bMemstat; /* True to enable memory status */ int bCoreMutex; /* True to enable core mutexing */ int bFullMutex; /* True to enable full mutexing */ int mxStrlen; /* Maximum string length */ int szLookaside; /* Default lookaside buffer size */ int nLookaside; /* Default lookaside buffer count */ sqlite4_mem_methods m; /* Low-level memory allocation interface */ sqlite4_mutex_methods mutex; /* Low-level mutex interface */ sqlite4_pcache_methods2 pcache2; /* Low-level page-cache interface */ void *pHeap; /* Heap storage space */ |
︙ | ︙ |
Changes to src/tclsqlite.c.
︙ | ︙ | |||
2450 2451 2452 2453 2454 2455 2456 | if( Tcl_GetBooleanFromObj(interp, objv[i+1], &b) ) return TCL_ERROR; if( b ){ flags |= SQLITE_OPEN_FULLMUTEX; flags &= ~SQLITE_OPEN_NOMUTEX; }else{ flags &= ~SQLITE_OPEN_FULLMUTEX; } | < < < < < < < < | 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 | if( Tcl_GetBooleanFromObj(interp, objv[i+1], &b) ) return TCL_ERROR; if( b ){ flags |= SQLITE_OPEN_FULLMUTEX; flags &= ~SQLITE_OPEN_NOMUTEX; }else{ flags &= ~SQLITE_OPEN_FULLMUTEX; } }else{ Tcl_AppendResult(interp, "unknown option: ", zArg, (char*)0); return TCL_ERROR; } } if( objc<3 || (objc&1)!=1 ){ Tcl_WrongNumArgs(interp, 1, objv, |
︙ | ︙ |
Changes to src/test1.c.
︙ | ︙ | |||
3342 3343 3344 3345 3346 3347 3348 | { "SQLITE_OPEN_MAIN_JOURNAL", SQLITE_OPEN_MAIN_JOURNAL }, { "SQLITE_OPEN_TEMP_JOURNAL", SQLITE_OPEN_TEMP_JOURNAL }, { "SQLITE_OPEN_SUBJOURNAL", SQLITE_OPEN_SUBJOURNAL }, { "SQLITE_OPEN_MASTER_JOURNAL", SQLITE_OPEN_MASTER_JOURNAL }, { "SQLITE_OPEN_NOMUTEX", SQLITE_OPEN_NOMUTEX }, { "SQLITE_OPEN_FULLMUTEX", SQLITE_OPEN_FULLMUTEX }, { "SQLITE_OPEN_WAL", SQLITE_OPEN_WAL }, | < | 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 | { "SQLITE_OPEN_MAIN_JOURNAL", SQLITE_OPEN_MAIN_JOURNAL }, { "SQLITE_OPEN_TEMP_JOURNAL", SQLITE_OPEN_TEMP_JOURNAL }, { "SQLITE_OPEN_SUBJOURNAL", SQLITE_OPEN_SUBJOURNAL }, { "SQLITE_OPEN_MASTER_JOURNAL", SQLITE_OPEN_MASTER_JOURNAL }, { "SQLITE_OPEN_NOMUTEX", SQLITE_OPEN_NOMUTEX }, { "SQLITE_OPEN_FULLMUTEX", SQLITE_OPEN_FULLMUTEX }, { "SQLITE_OPEN_WAL", SQLITE_OPEN_WAL }, { 0, 0 } }; rc = Tcl_GetIndexFromObjStruct(interp, apFlag[i], aFlag, sizeof(aFlag[0]), "flag", 0, &iFlag ); if( rc!=TCL_OK ) return rc; flags |= aFlag[iFlag].flag; |
︙ | ︙ |
Changes to src/test_malloc.c.
︙ | ︙ | |||
1168 1169 1170 1171 1172 1173 1174 | (char*)0); return TCL_ERROR; } } return TCL_OK; } | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 | (char*)0); return TCL_ERROR; } } return TCL_OK; } /* ** Usage: ** ** sqlite4_dump_memsys3 FILENAME ** sqlite4_dump_memsys5 FILENAME ** ** Write a summary of unfreed memsys3 allocations to FILENAME. |
︙ | ︙ | |||
1428 1429 1430 1431 1432 1433 1434 | { "sqlite4_status", test_status ,0 }, { "sqlite4_db_status", test_db_status ,0 }, { "install_malloc_faultsim", test_install_malloc_faultsim ,0 }, { "sqlite4_config_heap", test_config_heap ,0 }, { "sqlite4_config_memstatus", test_config_memstatus ,0 }, { "sqlite4_config_lookaside", test_config_lookaside ,0 }, { "sqlite4_config_error", test_config_error ,0 }, | < | 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 | { "sqlite4_status", test_status ,0 }, { "sqlite4_db_status", test_db_status ,0 }, { "install_malloc_faultsim", test_install_malloc_faultsim ,0 }, { "sqlite4_config_heap", test_config_heap ,0 }, { "sqlite4_config_memstatus", test_config_memstatus ,0 }, { "sqlite4_config_lookaside", test_config_lookaside ,0 }, { "sqlite4_config_error", test_config_error ,0 }, { "sqlite4_db_config_lookaside",test_db_config_lookaside ,0 }, { "sqlite4_dump_memsys3", test_dump_memsys3 ,3 }, { "sqlite4_dump_memsys5", test_dump_memsys3 ,5 }, { "sqlite4_install_memsys3", test_install_memsys3 ,0 }, }; int i; for(i=0; i<sizeof(aObjCmd)/sizeof(aObjCmd[0]); i++){ ClientData c = (ClientData)SQLITE_INT_TO_PTR(aObjCmd[i].clientData); Tcl_CreateObjCommand(interp, aObjCmd[i].zName, aObjCmd[i].xProc, c, 0); } return TCL_OK; } #endif |