From 2e92208c3c97672efad3b5d65889a048bbebdea1 Mon Sep 17 00:00:00 2001 From: ksooo <3226626+ksooo@users.noreply.github.com> Date: Fri, 6 Sep 2024 16:30:55 +0200 Subject: [PATCH] Fixup updating comment in _dvr_entry_update. Only overwrite existing title if comment is not NULL. Follows the same logic now as other updates done in this function. --- src/dvr/dvr_db.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dvr/dvr_db.c b/src/dvr/dvr_db.c index 153e11d4b..232b3e15f 100644 --- a/src/dvr/dvr_db.c +++ b/src/dvr/dvr_db.c @@ -2569,9 +2569,9 @@ static dvr_entry_t *_dvr_entry_update } /* Comment */ - if (strcmp(de->de_comment ?: "", comment ?: "")) { + if (comment && strcmp(de->de_comment ?: "", comment)) { free(de->de_comment); - de->de_comment = comment ? strdup(comment) : NULL; + de->de_comment = strdup(comment); save |= DVR_UPDATED_COMMENT; } -- 2.47.3