diff --git a/src/ckdb.c b/src/ckdb.c index 05169fc1..3c8d532c 100644 --- a/src/ckdb.c +++ b/src/ckdb.c @@ -4178,8 +4178,14 @@ static enum cmd_values breakdown(K_ITEM **ml_item, char *buf, tv_t *now, K_WUNLOCK(transfer_free); DATA_TRANSFER(transfer, t_item); STRNCPY(transfer->name, data); - STRNCPY(transfer->svalue, eq); - transfer->mvalue = transfer->svalue; + siz = strlen(eq) + 1; + if (siz > sizeof(transfer->svalue)) { + transfer->mvalue = malloc(siz); + STRNCPYSIZ(transfer->mvalue, eq, siz); + } else { + STRNCPYSIZ(transfer->svalue, eq, siz); + transfer->mvalue = transfer->svalue; + } // Discard duplicates if (find_in_ktree_nolock(msgline->trf_root, t_item, ctx)) { diff --git a/src/ckdb.h b/src/ckdb.h index 57462e88..143f62fd 100644 --- a/src/ckdb.h +++ b/src/ckdb.h @@ -58,7 +58,7 @@ #define DB_VLOCK "1" #define DB_VERSION "1.0.7" -#define CKDB_VERSION DB_VERSION"-2.433" +#define CKDB_VERSION DB_VERSION"-2.435" #define WHERE_FFL " - from %s %s() line %d" #define WHERE_FFL_HERE __FILE__, __func__, __LINE__