Bound upload cache growth and reject stale transfer completions

This commit is contained in:
evgeny committed 2026-10-06 12:46:32 +02:00
1 parent 972910c763
commit 8b327a3f27
3 files changed
+12 -2

No files matched your search

+3 -1
View File
@@ -131,7 +131,9 @@ static int profile_update_channel(struct UTUN_INSTANCE* inst, const char* ch, in
uint64_t local_uts = 0;
struct profile_json profile = { .text = "{", .used = 1, .avatar = avatar };
if (profile_pair(&profile, "name", inst->name) < 0) return -1;
if (profile_pair(&profile, "name", inst->name) < 0) {
DEBUG_ERROR(DEBUG_CATEGORY_CHAT, "profile: display name exceeds profile limit channel=%s", ch); return -1;
}
{ char q[256]; snprintf(q, sizeof(q), "SELECT update_ts,userinfo FROM \"%s\" WHERE node_id=?", tbl);
sqlite3_stmt* ps = NULL;
if (sqlite3_prepare_v2(cc->db, q, -1, &ps, NULL) == SQLITE_OK) {