winlin

copy the request for hls.

... ... @@ -1117,6 +1117,7 @@ int SrsHlsCache::reap_segment(string log_desc, SrsHlsMuxer* muxer, int64_t segme
SrsHls::SrsHls()
{
_req = NULL;
source = NULL;
handler = NULL;
... ... @@ -1137,6 +1138,7 @@ SrsHls::SrsHls()
SrsHls::~SrsHls()
{
srs_freep(_req);
srs_freep(codec);
srs_freep(sample);
srs_freep(jitter);
... ... @@ -1205,7 +1207,8 @@ int SrsHls::on_publish(SrsRequest* req)
{
int ret = ERROR_SUCCESS;
_req = req;
srs_freep(_req);
_req = req->copy();
// update the hls time, for hls_dispose.
last_update_time = srs_get_system_time_ms();
... ...