fixed the following issues with detection of flow control mode
o the flow control contig frame thresh should be based on max array size o it appears that the wakeup mechanism for the send thread, who sends the flow control on/off messages was broken o looking at full buffers isnt a perfect detection scheme compared to the simpler approach of just checking to see if bytes are pending in the socket before calling recv
This commit is contained in:
@@ -143,6 +143,7 @@ cac::cac (
|
||||
initializingThreadsId ( epicsThreadGetIdSelf() ),
|
||||
initializingThreadsPriority ( epicsThreadGetPrioritySelf() ),
|
||||
maxRecvBytesTCP ( MAX_TCP ),
|
||||
maxContigFrames ( contiguousMsgCountWhichTriggersFlowControl ),
|
||||
beaconAnomalyCount ( 0u ),
|
||||
iiuExistenceCount ( 0u )
|
||||
{
|
||||
@@ -215,6 +216,11 @@ cac::cac (
|
||||
if ( ! this->tcpLargeRecvBufFreeList ) {
|
||||
throw std::bad_alloc ();
|
||||
}
|
||||
unsigned bufsPerArray = this->maxRecvBytesTCP / comBuf::capacityBytes ();
|
||||
if ( bufsPerArray > 1u ) {
|
||||
maxContigFrames = bufsPerArray *
|
||||
contiguousMsgCountWhichTriggersFlowControl;
|
||||
}
|
||||
}
|
||||
catch ( ... ) {
|
||||
osiSockRelease ();
|
||||
|
||||
Reference in New Issue
Block a user