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

refine the thread, add all callback.

This commit is contained in:
winlin 2015-05-23 09:49:15 +08:00
parent e5f449ce36
commit cfc0877ec9
9 changed files with 341 additions and 57 deletions

View file

@ -48,7 +48,7 @@ class SrsKbps;
* forward the stream to other servers.
*/
// TODO: FIXME: refine the error log, comments it.
class SrsForwarder : public ISrsReusableThreadHandler
class SrsForwarder : public ISrsReusableThread2Handler
{
private:
// the ep to forward, server[:port].
@ -57,7 +57,7 @@ private:
int stream_id;
private:
st_netfd_t stfd;
SrsReusableThread* pthread;
SrsReusableThread2* pthread;
private:
SrsSource* source;
ISrsProtocolReaderWriter* io;
@ -95,7 +95,7 @@ public:
* @param shared_video, directly ptr, copy it if need to save it.
*/
virtual int on_video(SrsSharedPtrMessage* shared_video);
// interface ISrsReusableThreadHandler.
// interface ISrsReusableThread2Handler.
public:
virtual int cycle();
private: