1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

disable the hls_dispose by default to 0, for p2p system should never cleanup for timeshift hls.

This commit is contained in:
winlin 2015-06-03 10:13:46 +08:00
parent 4e42b9c628
commit af9efe9213
3 changed files with 12 additions and 3 deletions

View file

@ -3566,7 +3566,7 @@ int SrsConfig::get_hls_dispose(string vhost)
{
SrsConfDirective* conf = get_hls(vhost);
int DEFAULT = 300;
int DEFAULT = 0;
if (!conf) {
return DEFAULT;

View file

@ -1155,6 +1155,14 @@ void SrsHls::dispose()
on_unpublish();
}
// only dispose hls when positive.
if (_req) {
int hls_dispose = _srs_config->get_hls_dispose(_req->vhost);
if (hls_dispose <= 0) {
return;
}
}
muxer->dispose();
}