mirror of
https://github.com/ossrs/srs.git
synced 2025-02-15 04:42:04 +00:00
Merge
This commit is contained in:
commit
2080d1b2b3
5 changed files with 15 additions and 8 deletions
|
@ -276,6 +276,7 @@ The ports used by SRS:
|
||||||
|
|
||||||
## V3 changes
|
## V3 changes
|
||||||
|
|
||||||
|
* v3.0, 2021-05-12, Fix [#2311][bug #2311], Copy the request for stat client. 3.0.162
|
||||||
* <strong>v3.0, 2021-04-28, [3.0 release5(3.0.161)][r3.0r5] released. 122750 lines.</strong>
|
* <strong>v3.0, 2021-04-28, [3.0 release5(3.0.161)][r3.0r5] released. 122750 lines.</strong>
|
||||||
* v3.0, 2021-04-28, Upgrade players. 3.0.161
|
* v3.0, 2021-04-28, Upgrade players. 3.0.161
|
||||||
* <strong>v3.0, 2021-04-24, [3.0 release4(3.0.160)][r3.0r4] released. 122750 lines.</strong>
|
* <strong>v3.0, 2021-04-24, [3.0 release4(3.0.160)][r3.0r4] released. 122750 lines.</strong>
|
||||||
|
@ -1912,6 +1913,7 @@ Winlin
|
||||||
[bug #1987]: https://github.com/ossrs/srs/issues/1987
|
[bug #1987]: https://github.com/ossrs/srs/issues/1987
|
||||||
[bug #1548]: https://github.com/ossrs/srs/issues/1548
|
[bug #1548]: https://github.com/ossrs/srs/issues/1548
|
||||||
[bug #1694]: https://github.com/ossrs/srs/issues/1694
|
[bug #1694]: https://github.com/ossrs/srs/issues/1694
|
||||||
|
[bug #2311]: https://github.com/ossrs/srs/issues/2311
|
||||||
[bug #413]: https://github.com/ossrs/srs/issues/413
|
[bug #413]: https://github.com/ossrs/srs/issues/413
|
||||||
[bug #2091]: https://github.com/ossrs/srs/issues/2091
|
[bug #2091]: https://github.com/ossrs/srs/issues/2091
|
||||||
[bug #1342]: https://github.com/ossrs/srs/issues/1342
|
[bug #1342]: https://github.com/ossrs/srs/issues/1342
|
||||||
|
|
|
@ -76,7 +76,7 @@ SrsBufferCache::~SrsBufferCache()
|
||||||
srs_freep(req);
|
srs_freep(req);
|
||||||
}
|
}
|
||||||
|
|
||||||
srs_error_t SrsBufferCache::update(SrsSource* s, SrsRequest* r)
|
srs_error_t SrsBufferCache::update_auth(SrsSource* s, SrsRequest* r)
|
||||||
{
|
{
|
||||||
srs_freep(req);
|
srs_freep(req);
|
||||||
req = r->copy();
|
req = r->copy();
|
||||||
|
@ -527,7 +527,7 @@ SrsLiveStream::~SrsLiveStream()
|
||||||
srs_freep(req);
|
srs_freep(req);
|
||||||
}
|
}
|
||||||
|
|
||||||
srs_error_t SrsLiveStream::update(SrsSource* s, SrsRequest* r)
|
srs_error_t SrsLiveStream::update_auth(SrsSource* s, SrsRequest* r)
|
||||||
{
|
{
|
||||||
source = s;
|
source = s;
|
||||||
|
|
||||||
|
@ -953,9 +953,10 @@ srs_error_t SrsHttpStreamServer::http_mount(SrsSource* s, SrsRequest* r)
|
||||||
}
|
}
|
||||||
srs_trace("http: mount flv stream for sid=%s, mount=%s", sid.c_str(), mount.c_str());
|
srs_trace("http: mount flv stream for sid=%s, mount=%s", sid.c_str(), mount.c_str());
|
||||||
} else {
|
} else {
|
||||||
|
// The entry exists, we reuse it and update the request of stream and cache.
|
||||||
entry = sflvs[sid];
|
entry = sflvs[sid];
|
||||||
entry->stream->update(s, r);
|
entry->stream->update_auth(s, r);
|
||||||
entry->cache->update(s, r);
|
entry->cache->update_auth(s, r);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (entry->stream) {
|
if (entry->stream) {
|
||||||
|
|
|
@ -46,7 +46,7 @@ private:
|
||||||
public:
|
public:
|
||||||
SrsBufferCache(SrsSource* s, SrsRequest* r);
|
SrsBufferCache(SrsSource* s, SrsRequest* r);
|
||||||
virtual ~SrsBufferCache();
|
virtual ~SrsBufferCache();
|
||||||
virtual srs_error_t update(SrsSource* s, SrsRequest* r);
|
virtual srs_error_t update_auth(SrsSource* s, SrsRequest* r);
|
||||||
public:
|
public:
|
||||||
virtual srs_error_t start();
|
virtual srs_error_t start();
|
||||||
virtual srs_error_t dump_cache(SrsConsumer* consumer, SrsRtmpJitterAlgorithm jitter);
|
virtual srs_error_t dump_cache(SrsConsumer* consumer, SrsRtmpJitterAlgorithm jitter);
|
||||||
|
@ -189,7 +189,7 @@ private:
|
||||||
public:
|
public:
|
||||||
SrsLiveStream(SrsSource* s, SrsRequest* r, SrsBufferCache* c);
|
SrsLiveStream(SrsSource* s, SrsRequest* r, SrsBufferCache* c);
|
||||||
virtual ~SrsLiveStream();
|
virtual ~SrsLiveStream();
|
||||||
virtual srs_error_t update(SrsSource* s, SrsRequest* r);
|
virtual srs_error_t update_auth(SrsSource* s, SrsRequest* r);
|
||||||
public:
|
public:
|
||||||
virtual srs_error_t serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r);
|
virtual srs_error_t serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r);
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -460,10 +460,14 @@ srs_error_t SrsStatistic::on_client(SrsContextId cid, SrsRequest* req, ISrsExpir
|
||||||
|
|
||||||
// got client.
|
// got client.
|
||||||
client->conn = conn;
|
client->conn = conn;
|
||||||
client->req = req;
|
|
||||||
client->type = type;
|
client->type = type;
|
||||||
stream->nb_clients++;
|
stream->nb_clients++;
|
||||||
vhost->nb_clients++;
|
vhost->nb_clients++;
|
||||||
|
|
||||||
|
// The req might be freed, in such as SrsLiveStream::update, so we must copy it.
|
||||||
|
// @see https://github.com/ossrs/srs/issues/2311
|
||||||
|
srs_freep(client->req);
|
||||||
|
client->req = req->copy();
|
||||||
|
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,6 +26,6 @@
|
||||||
|
|
||||||
#define VERSION_MAJOR 3
|
#define VERSION_MAJOR 3
|
||||||
#define VERSION_MINOR 0
|
#define VERSION_MINOR 0
|
||||||
#define SRS_VERSION3_REVISION 161
|
#define SRS_VERSION3_REVISION 162
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue