Merge branch 'master' into merge/upstream-full
All checks were successful
CI Code / Check spelling (pull_request) Successful in 17s
CI Code / Check coding style (pull_request) Successful in 31s
CI Code / Linux (debian) (pull_request) Successful in 4m48s
CI Code / Linux (ubuntu) (pull_request) Successful in 4m56s
CI Code / Code Coverage (pull_request) Successful in 7m0s
CI Code / Linux (arch) (pull_request) Successful in 10m5s

Bring in master commits since the previous merge:
- 4776c1f1e fix(ai): properly decode \uXXXX JSON escape sequences as UTF-8
- 53cdf488b fix(ai): resolve UAF and require provider argument instead of defaults
- 3b673150b chore(chatlog): disable background message file logging (stage 1)

Conflict in src/chatlog.c: master stubs out all chat_log_* function
bodies (project policy — disable plain-text per-day chatlogs), while
the upstream-merged version in this branch still had upstream's full
implementation. Taking master's version entirely keeps the no-op
chatlog API surface that the ~20 call sites in event/, otr/ and
profanity.c depend on.
This commit is contained in:
2026-05-21 11:58:26 +03:00
3 changed files with 171 additions and 390 deletions

View File

@@ -10823,21 +10823,14 @@ cmd_ai_start(ProfWin* window, const char* const command, gchar** args)
if (g_strv_length(args) >= 2) {
provider_name = args[1];
}
if (g_strv_length(args) >= 3) {
model = args[2];
if (!provider_name) {
cons_show_error("Please specify provider name.");
return TRUE;
}
// Resolve defaults
auto_gchar gchar* owned_provider_name = NULL;
if (!provider_name) {
// Use default provider from preferences
auto_gchar gchar* default_provider = prefs_get_string(PREF_AI_PROVIDER);
if (default_provider && strlen(default_provider) > 0) {
provider_name = default_provider;
}
}
if (!provider_name) {
provider_name = "openai"; // Fallback
if (g_strv_length(args) >= 3) {
model = args[2];
}
AIProvider* provider = ai_get_provider(provider_name);