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

Fix #786, simply don't reuse object. 3.0.20

This commit is contained in:
winlin 2017-03-02 16:43:06 +08:00
parent 7680ac04ad
commit 308c6fee18
9 changed files with 38 additions and 19 deletions

View file

@ -193,7 +193,7 @@ SrsRtspConn::SrsRtspConn(SrsRtspCaster* c, st_netfd_t fd, std::string o)
caster = c;
stfd = fd;
skt = new SrsStSocket(fd);
skt = new SrsStSocket();
rtsp = new SrsRtspStack(skt);
trd = new SrsOneCycleThread("rtsp", this);
@ -232,6 +232,11 @@ SrsRtspConn::~SrsRtspConn()
int SrsRtspConn::serve()
{
int ret = ERROR_SUCCESS;
if ((ret = skt->initialize(stfd)) != ERROR_SUCCESS) {
return ret;
}
return trd->start();
}