diff --git a/src/muxer.c b/src/muxer.c index 2d737327..a07e02cf 100644 --- a/src/muxer.c +++ b/src/muxer.c @@ -251,11 +251,12 @@ muxer_create(muxer_container_type_t mc, muxer_config_t *m_cfg) m = lav_muxer_create(mc, m_cfg); #endif - if(!m) + if(!m) { tvhlog(LOG_ERR, "mux", "Can't find a muxer that supports '%s' container", muxer_container_type2txt(mc)); - else - m->m_cache = m_cfg->dvr_cache; + return NULL; + } + m->m_cache = m_cfg ? m_cfg->dvr_cache : MC_CACHE_SYSTEM; return m; } diff --git a/src/webui/webui.c b/src/webui/webui.c index ca5f5f52..6fc7d658 100644 --- a/src/webui/webui.c +++ b/src/webui/webui.c @@ -787,6 +787,7 @@ http_stream_channel(http_connection_t *hc, channel_t *ch, int weight) mc = cfg->dvr_mc; } m_cfg.dvr_flags = cfg->dvr_mux_flags; + m_cfg.dvr_cache = cfg->dvr_mux_cache; if ((str = http_arg_get(&hc->hc_req_args, "qsize"))) qsize = atoll(str);