1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-30 19:03:16 +03:00

When readline is enabled, attempt to determine whether the completion API is compatible and, if it's not, disable it in the shell app.

FossilOrigin-Name: 4564dbe4ac0040803b5d139c9fff22a60a45b4769d80ad7c824456cc6b9f1722
This commit is contained in:
stephan
2024-10-27 18:46:11 +00:00
parent 6d05f9af81
commit 9905e7e22b
5 changed files with 34 additions and 13 deletions

View File

@ -5759,7 +5759,8 @@ void close_db(sqlite3 *db){
}
}
#if HAVE_READLINE || HAVE_EDITLINE
#if (HAVE_READLINE || HAVE_EDITLINE) \
&& !defined(SQLITE_OMIT_READLINE_COMPLETION)
/*
** Readline completion callbacks
*/
@ -13259,7 +13260,7 @@ int SQLITE_CDECL wmain(int argc, wchar_t **wargv){
}
}
if( zHistory ){ shell_read_history(zHistory); }
#if HAVE_READLINE || HAVE_EDITLINE
#if (HAVE_READLINE || HAVE_EDITLINE) && !defined(SQLITE_OMIT_READLINE_COMPLETION)
rl_attempted_completion_function = readline_completion;
#elif HAVE_LINENOISE
linenoiseSetCompletionCallback(linenoise_completion, NULL);