<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi,<div><br></div><div>I am trying to get live RTP data as input to the RTSP Server.</div><div><br></div><div>Modified H264VideoFileServerMediaSubsession::createNewStreamSource to  create a RTPSource instead of ByteStreamFileSource. </div><div><br></div><div><div><font class="Apple-style-span" face="Courier">  char const* inputAddressStr = "0.0.0.0";</font></div><div><font class="Apple-style-span" face="Courier">  struct in_addr inputAddress;</font></div><div><font class="Apple-style-span" face="Courier">  inputAddress.s_addr = our_inet_addr(inputAddressStr);</font></div><div><font class="Apple-style-span" face="Courier">  Port const inputPort(50003);</font></div><div><font class="Apple-style-span" face="Courier">  unsigned char const inputTTL = 0; // we're only reading from this mcast group</font></div><div><font class="Apple-style-span" face="Courier">  Groupsock inputGroupsock(envir(), inputAddress, inputPort, inputTTL);</font></div><div>     <font class="Apple-style-span" face="Courier">H264VideoRTPSource *rtpSource = </font><font class="Apple-style-span" face="Courier">H264VideoRTPSource::createNew(envir(), &inputGroupsock,96,90000);</font></div><div><span class="Apple-style-span" style="font-family: Courier; ">  return H264VideoStreamDiscreteFramer::createNew(envir(), rtpSource);</span></div></div><div><br></div><div>The program is crashing when RTPInterface::startNetworkReading calls  BasicTaskScheduler::setBackgroundHandling. From the gdb trace found that the socketNum in RTPInterface is corrupted. </div><div>When the RTPInterface object was initialized its value was 6.  </div><div>Any idea where things might be going wrong ?</div><div><br></div><div>GDB Trace when the application crashed. </div><div><br></div><div><div><font class="Apple-style-span" face="Courier">BasicTaskScheduler::setBackgroundHandling (this=0x1002008c0, <b>socketNum=1606412024</b>, conditionSet=2, handlerProc=0xbf7fe24, clientData=0x7fff8d02a600) at BasicTaskScheduler.cpp:197</font></div><div><font class="Apple-style-span" face="Courier">RTPInterface::startNetworkReading (this=0x100204d90, handlerProc=0x10001b2d8 <MultiFramedRTPSource::networkReadHandler(MultiFramedRTPSource*, int)>) at UsageEnvironment.hh:156</font></div><div><font class="Apple-style-span" face="Courier">MultiFramedRTPSource::doGetNextFrame (this=0x0) at MultiFramedRTPSource.cpp:119</font></div><div><font class="Apple-style-span" face="Courier">H264VideoStreamDiscreteFramer::doGetNextFrame (this=0x100204d00) at H264VideoStreamDiscreteFramer.cpp:46</font></div><div><font class="Apple-style-span" face="Courier">H264FUAFragmenter::doGetNextFrame (this=0x0) at H264VideoRTPSink.cpp:167</font></div><div><font class="Apple-style-span" face="Courier">MultiFramedRTPSink::packFrame (this=0x0) at MultiFramedRTPSink.cpp:216</font></div><div><font class="Apple-style-span" face="Courier">MultiFramedRTPSink::continuePlaying (this=0x0) at MultiFramedRTPSink.cpp:152</font></div><div><font class="Apple-style-span" face="Courier">StreamState::startPlaying (this=0x1002055d0, dests=0x7fff5fbfe6f8, rtcpRRHandler=0x100020ac4 <RTSPServer::RTSPClientSession::noteClientLiveness(RTSPServer::RTSPClientSession*)>, rtcpRRHandlerClientData=0x7fff5fbff1c0, serverRequestAlternativeByteHandler=0x100022dac <RTSPServer::RTSPClientSession::handleAlternativeRequestByte(void*, unsigned char)>, serverRequestAlternativeByteHandlerClientData=0x100801600) at OnDemandServerMediaSubsession.cpp:427</font></div><div><font class="Apple-style-span" face="Courier">OnDemandServerMediaSubsession::startStream (this=0x0, clientSessionId=1606412024, streamToken=0x1002055d0, rtcpRRHandler=0, rtcpRRHandlerClientData=0x10001b2d8, rtpSeqNum=@0x7fff5fbff266, rtpTimestamp=@0x7fff5fbff260, serverRequestAlternativeByteHandler=0x100022dac <RTSPServer::RTSPClientSession::handleAlternativeRequestByte(void*, unsigned char)>, serverRequestAlternativeByteHandlerClientData=0x100801600) at OnDemandServerMediaSubsession.cpp:210</font></div><div><font class="Apple-style-span" face="Courier">RTSPServer::RTSPClientSession::handleCmd_PLAY (this=0x100801600, subsession=0x7fff5fbff320, cseq=0x7fff5fbff320 "??_?", fullRequestStr=0x7fff5fbff320 "??_?") at RTSPServer.cpp:1209</font></div></div><div><br></div><div><br></div><div>Regards,</div><div>Sambhav </div></body></html>