Skip to content

Commit b4fe55d

Browse files
authored
Merge pull request #2798 from pi-hole/update/sqlite3_52_0
Update embedded SQLite3 to 3.52.0
2 parents ba3c03b + dcff36e commit b4fe55d

7 files changed

Lines changed: 34076 additions & 29161 deletions

File tree

patch/sqlite3/0001-print-FTL-version-in-interactive-shell.patch

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,20 @@ index 6280ebf6..a5e82f70 100644
1111

1212
#if !defined(_WIN32) && !defined(WIN32)
1313
# include <signal.h>
14-
@@ -32902,7 +32904,7 @@ static char *cmdline_option_value(int argc, char **argv, int i){
15-
#endif
16-
17-
#if SQLITE_SHELL_IS_UTF8
14+
@@ -36236,7 +36236,7 @@ static char *cmdline_option_value(int argc, char **argv, int i){
15+
** fiddle_main In Fiddle
16+
** sqlite3_shell Other projects that use shell.c as a subroutine
17+
*/
1818
-int SQLITE_CDECL main(int argc, char **argv){
1919
+int SQLITE_CDECL sqlite3_shell_main(int argc, char **argv){
20-
#else
21-
int SQLITE_CDECL wmain(int argc, wchar_t **wargv){
22-
char **argv;
23-
@@ -33656,6 +33658,7 @@ int SQLITE_CDECL wmain(int argc, wchar_t **wargv){
20+
#ifdef SQLITE_DEBUG
21+
sqlite3_int64 mem_main_enter = 0;
22+
#endif
23+
@@ -36882,6 +36882,7 @@ int SQLITE_CDECL wmain(int argc, wchar_t **wargv){
2424
if( stdin_is_interactive ){
2525
char *zHome;
2626
char *zHistory;
2727
+ print_FTL_version();
28-
sqlite3_fprintf(stdout,
28+
cli_printf(stdout,
2929
"SQLite version %s %.19s\n" /*extra-version-info*/
3030
"Enter \".help\" for usage hints.\n",

patch/sqlite3/0002-make-sqlite3ErrName-public.patch

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ diff --git a/src/database/sqlite3.c b/src/database/sqlite3.c
22
index 2763b1b4..55f88efb 100644
33
--- a/src/database/sqlite3.c
44
+++ b/src/database/sqlite3.c
5-
@@ -182744,8 +182744,7 @@ SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3 *db, int tripCode){
5+
@@ -187749,8 +187749,7 @@ SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3 *db, int tripCode){
66
** Return a static string containing the name corresponding to the error code
77
** specified in the argument.
88
*/
@@ -12,7 +12,7 @@ index 2763b1b4..55f88efb 100644
1212
const char *zName = 0;
1313
int i, origRc = rc;
1414
for(i=0; i<2 && zName==0; i++, rc &= 0xff){
15-
@@ -182850,7 +182849,6 @@ SQLITE_PRIVATE const char *sqlite3ErrName(int rc){
15+
@@ -187856,7 +187856,6 @@ SQLITE_PRIVATE const char *sqlite3ErrName(int rc){
1616
}
1717
return zName;
1818
}

src/database/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ set(sqlite3_sources
2222
add_library(sqlite3 OBJECT ${sqlite3_sources})
2323
# Define the function that will be called to initialize the sqlite3 shell
2424
target_compile_definitions(sqlite3 PRIVATE "-DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_SHELL_INIT_PROC=pihole_sqlite3_initalize")
25-
target_compile_options(sqlite3 PRIVATE -Wno-implicit-fallthrough -Wno-cast-function-type -Wno-sign-compare -Wno-implicit-function-declaration -Wno-int-conversion)
25+
target_compile_options(sqlite3 PRIVATE -Wno-implicit-fallthrough -Wno-cast-function-type -Wno-sign-compare -Wno-implicit-function-declaration -Wno-int-conversion -Wno-unused-function)
2626

2727
if (CMAKE_C_COMPILER_ID STREQUAL "Clang")
2828
target_compile_options(sqlite3 PRIVATE "-Wno-null-pointer-subtraction")

0 commit comments

Comments
 (0)