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

For #1657, refine http api disconnect log

This commit is contained in:
winlin 2020-11-05 18:19:43 +08:00
parent 74799a31e3
commit 4b082ea96c
6 changed files with 23 additions and 11 deletions

View file

@ -68,7 +68,8 @@ public:
// For the stream caster, for instance, http flv streaming, may discard the flv header or not.
virtual srs_error_t on_http_message(ISrsHttpMessage* r, SrsHttpResponseWriter* w) = 0;
// When connection is destroy, should use manager to dispose it.
virtual void on_conn_done() = 0;
// The r0 is the original error, we will use the returned new error.
virtual srs_error_t on_conn_done(srs_error_t r0) = 0;
};
// The http connection which request the static or stream content.
@ -170,7 +171,7 @@ public:
public:
virtual srs_error_t on_start();
virtual srs_error_t on_http_message(ISrsHttpMessage* r, SrsHttpResponseWriter* w);
virtual void on_conn_done();
virtual srs_error_t on_conn_done(srs_error_t r0);
// Extract APIs from SrsTcpConnection.
public:
// Set socket option TCP_NODELAY.