From: Jaroslav Kysela Date: Thu, 3 Dec 2015 07:50:33 +0000 (+0100) Subject: DVR: cosmetic changes for the previous patch X-Git-Tag: v4.2.1~1398 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bba94abf06d1f1dc7fa8ba5420a83d575ce32235;p=thirdparty%2Ftvheadend.git DVR: cosmetic changes for the previous patch --- diff --git a/src/api/api_dvr.c b/src/api/api_dvr.c index 3ee87f0a3..9a455cb54 100644 --- a/src/api/api_dvr.c +++ b/src/api/api_dvr.c @@ -240,7 +240,8 @@ api_dvr_entry_create_by_event e, 0, 0, perm->aa_username, perm->aa_representative, - NULL, DVR_PRIO_NORMAL, DVR_RET_DVRCONFIG, DVR_RET_DVRCONFIG, comment); + NULL, DVR_PRIO_NORMAL, DVR_RET_DVRCONFIG, + DVR_RET_DVRCONFIG, comment); if (de) dvr_entry_save(de); } diff --git a/src/dvr/dvr_autorec.c b/src/dvr/dvr_autorec.c index 7e9122727..7187de0b6 100644 --- a/src/dvr/dvr_autorec.c +++ b/src/dvr/dvr_autorec.c @@ -1394,9 +1394,9 @@ uint32_t dvr_autorec_get_retention_days( dvr_autorec_entry_t *dae ) { if (dae->dae_retention > 0) { + uint32_t removal = dvr_autorec_get_removal_days(dae); /* As we need the db entry when deleting the file on disk */ - if (dvr_autorec_get_removal_days(dae) != DVR_RET_FOREVER && - dvr_autorec_get_removal_days(dae) > dae->dae_retention) + if (removal != DVR_RET_FOREVER && removal > dae->dae_retention) return DVR_RET_ONREMOVE; return dae->dae_retention; diff --git a/src/dvr/dvr_db.c b/src/dvr/dvr_db.c index 79c9ab892..3b7b5758a 100644 --- a/src/dvr/dvr_db.c +++ b/src/dvr/dvr_db.c @@ -388,7 +388,7 @@ dvr_entry_retention_timer(dvr_entry_t *de) uint32_t retention = dvr_entry_get_retention_days(de); stop = de->de_stop + removal * (time_t)86400; - if ((removal > 0 || retention == 0) && removal < DVR_RET_SPACENEED) { + if ((removal > 0 || retention == 0) && removal < DVR_RET_SPACENEED) { if (stop > dispatch_clock) { dvr_entry_retention_arm(de, dvr_timer_remove_files, stop); return; diff --git a/src/webui/simpleui.c b/src/webui/simpleui.c index d6888a005..ef69b1466 100644 --- a/src/webui/simpleui.c +++ b/src/webui/simpleui.c @@ -336,8 +336,8 @@ page_einfo(http_connection_t *hc, const char *remain, void *opaque) if((http_arg_get(&hc->hc_req_args, "rec")) != NULL) { de = dvr_entry_create_by_event(1, NULL, e, 0, 0, hc->hc_username ?: NULL, hc->hc_representative ?: NULL, NULL, - DVR_PRIO_NORMAL, DVR_RET_DVRCONFIG, - DVR_RET_DVRCONFIG, "simpleui"); + DVR_PRIO_NORMAL, DVR_RET_DVRCONFIG, + DVR_RET_DVRCONFIG, "simpleui"); } else if(de != NULL && (http_arg_get(&hc->hc_req_args, "cancel")) != NULL) { de = dvr_entry_cancel(de, 0); }