<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<base href=""><style>
<!--
@font-face
        {font-family:Wingdings}
@font-face
        {font-family:Wingdings}
@font-face
        {font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif"}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif"}
span.apple-converted-space
        {}
span.apple-style-span
        {}
span.EmailStyle19
        {font-family:"Calibri","sans-serif";
        color:#1F497D}
.MsoChpDefault
        {font-size:10.0pt}
@page WordSection1
        {margin:1.0in 1.0in 1.0in 1.0in}
div.WordSection1
        {}
ol
        {margin-bottom:0in}
ul
        {margin-bottom:0in}
-->
</style>
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal" style="margin-left:.5in">In any case, I don't have time to speculate back and forth on this mailing list (for free) about this problem.  Right now, because you're the only person encountering this, you're going to have to track it down
 yourself.  Sorry.</p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Here is what I found:</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#1. When the backend server goes away unceremoniously, the ‘readSocket()’ in ‘SocketDescriptor::tcpReadHandler1()’ will set ‘fDeleteMyselfNext’ – this causes
 ‘SocketDescriptor::tcpReadHandler()’ to delete the ‘socketDescriptor’. Note that ‘fAreInReadHandlerLoop’ reset back to False before deleting the ‘socketDescriptor’</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#2. ‘SocketDescriptor::~SocketDescriptor()’ then invokes RTSPClient’s ‘fServerRequestAlternativeByteHandler’ with 0xFF (ReadErrorOccured)</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#3. For ProxyServerMediaSession, this results in negative return for OPTIONS command sent during Liveness.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#4. ‘continueAfterLivenessCommand’ gets invoked, and thereby everything is being reset.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#5. As part of those reset handling RTCPInstances gets closed – which results in deregistering from RTPInterface.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#6. ‘SocketDescriptor::deregisterRTPInterface’ will then remove the reference of the SocketDescriptor from ‘fSubChannelHasTable’ – and once this is empty,
  and since ‘fAreInReadHandlerLoop’ is False (refer #1 above), this will go on to delete ‘socketDescriptor’ yet again. This deletion is successfully completed – resulting in successful ‘removeSocketDescription()’.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">#7. After all clean-up, the ‘fServerRequestAlternativeByteHandler’ (from #2 above) finally returns back to the SocketDescriptor destructor, and it crashes
 in next call to ‘removeSocketDescription’. SocketDescriptor is no longer a valid object at this point – it is already been deleted in #6.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Any of the following seems to work for my use case:</span></p>
<p class="MsoListParagraph" style="text-indent:-.25in"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"><span style="">-<span style="font:7.0pt "Times New Roman"">         
</span></span></span><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Moving invocation of ‘fServerRequestAlternativeByteHandler’ to bottom of ‘SocketDescriptor::~SocketDescriptor()’</span></p>
<p class="MsoListParagraph" style="text-indent:-.25in"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"><span style="">-<span style="font:7.0pt "Times New Roman"">         
</span></span></span><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Moving ‘socketDescriptor->fAreInReadHandlerLoop = False;’ to bottom of ‘SocketDescriptor::tcpReadHandler()’</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Many thanks,</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D">Subhankar.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri","sans-serif"; color:#1F497D"> </span></p>
</div>
<br>
<hr>
<font face="Arial" color="Gray" size="1"><br>
http://www.mindtree.com/email/disclaimer.html<br>
</font>
</body>
</html>