You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Should we add seqoff() into the abs() below (in group.cpp)?
if (m_RcvBaseSeqNo != SRT_SEQNO_NONE && abs(m_RcvBaseSeqNo - mctrl.pktseq) > CSeqNo::m_iSeqNoTH)
{
// This error should be returned if the link turns out
// to be the only one, or set to the group data.
// err = SRT_ESECFAIL;
LOGC(grlog.Error,
log << "group/recv: @" << id << ": SEQUENCE DISCREPANCY: base=%" << m_RcvBaseSeqNo
<< " vs pkt=%" << mctrl.pktseq << ", setting ESECFAIL");
broken.insert(ps);
break;
}
then deadlock
(gdb) where
#0 0x00007f15a2b9e98d in pthread_join () from target:/home/jingchi/remote_server/lib/libpthread.so.0
#1 0x00007f15a1479d63 in std::thread::join() () from target:/home/jingchi/remote_server/lib/libstdc++.so.6
#2 0x00007f15a3519c4d in srt::CUDT::releaseSynch() () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
#3 0x00007f15a3532e88 in srt::CUDT::closeInternal() () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
#4 0x00007f15a34f71ef in srt::CUDTUnited::close(srt::CUDTSocket*) () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
#5 0x00007f15a358038c in srt::CUDTGroup::recv(char*, int, SRT_MsgCtrl_&) () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
#6 0x00007f15a34ebb17 in srt::CUDT::recvmsg2(int, char*, int, SRT_MsgCtrl_&) () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
#7 0x00007f15a357135e in srt_recvmsg2 () from target:/home/jingchi/remote_server/lib/libsrt.so.1.4
To Reproduce
SRT broadcast video to server in live mode.
Expected behavior
The normal pkt seq overflow from 2147483647 to 0 should not cause close().
close() should not cause deadlock
Desktop (please provide the following information):
OS: Linux
SRT Version / commit ID: v1.4.4-rc.1
The text was updated successfully, but these errors were encountered:
// Force closing
{
InvertedLock ung (m_GroupLock);
for (set<CUDTSocket*>::iterator b = broken.begin(); b != broken.end(); ++b)
{
CUDT::s_UDTUnited.close(*b);
}
}
When Group::recv() call close(), it should not hold any lock, but from the log and backtrace, it was holding a lock needed by tsbpd(), can we just report error here, and let applications to close the broken sockets?
@gou4shi1
So far I think It would probably be better to just mark a socket as "broken", thus it would be eventually closed in a background GC thread.
PR #2142 addresses the first issue described here.
Thus the send issue (hang up) is less likely to happen and can be postponed to v1.4.5 to reduce the number of changes in SRT RC.1.
Describe the bug
There are two problems:
2147483647
to0
causedGroup::recv()
to close all members, you can found that by theSEQUENCE DISCREPANCY
log belowShould we add
seqoff()
into theabs()
below (ingroup.cpp
)?To Reproduce
SRT broadcast video to server in live mode.
Expected behavior
2147483647
to0
should not causeclose()
.close()
should not cause deadlockDesktop (please provide the following information):
The text was updated successfully, but these errors were encountered: