[prev in list] [next in list] [prev in thread] [next in thread] 

List:       helix-server-cvs
Subject:    [Server-cvs] broadcast/transport/rtp/recv rtpreceiver.cpp, 1.9, 1.9.18.1
From:       packard () helixcommunity ! org
Date:       2013-04-28 7:31:57
[Download RAW message or body]

Update of /cvsroot/server/broadcast/transport/rtp/recv
In directory cvs01.internal.helixcommunity.org:/tmp/cvs-serv25459

Modified Files:
      Tag: SERVER_VHOST_YIJI_2
	rtpreceiver.cpp 
Log Message:
Reviewed by Richard

Synopsis
========
CR: rtp ingress support for vhost

Branches: SERVER_VHOST_YIJI_2

Reviewer: Anyone

Description
===========
Add vhost support for rtp ingress.

Files Affected
==============
/cvsroot/server/broadcast/transport/rtp/recv/rtpbcobj.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpbcplin.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpbcstreams.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpdirmgr.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtplivestream.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpreceiver.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpstream.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/rtpworkercb.cpp,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpbcobj.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpbcplin.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpbcstreams.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpdirmgr.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtplivestream.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpreceiver.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpstream.h,v
/cvsroot/server/broadcast/transport/rtp/recv/pub/rtpworkercb.h,v
/cvsroot/server/common/util/livepacketq.cpp,v
/cvsroot/server/common/util/pub/livepacketq.h

Testing Performed
=================
Integration Tests: enable dir scan or disable dir scan both work.





Index: rtpreceiver.cpp
===================================================================
RCS file: /cvsroot/server/broadcast/transport/rtp/recv/rtpreceiver.cpp,v
retrieving revision 1.9
retrieving revision 1.9.18.1
diff -u -d -r1.9 -r1.9.18.1
--- rtpreceiver.cpp	6 Feb 2012 07:29:00 -0000	1.9
+++ rtpreceiver.cpp	28 Apr 2013 07:31:49 -0000	1.9.18.1
@@ -101,7 +101,7 @@
  *
  *  Constructor
  */
-RTPSocketHandler::RTPSocketHandler(IUnknown* pContext, BOOL bSourceAddressFilter)
+RTPSocketHandler::RTPSocketHandler(IUnknown* pContext, BOOL bSourceAddressFilter, \
IHXValues*pVhostInfo)  : m_lRefCount       (0)
       , m_pContext      (NULL)
       , m_ulLocalAddr   (0)
@@ -114,11 +114,13 @@
       , m_pLastResponse (NULL)
       , m_bSourceAddressFilter(bSourceAddressFilter)
       , m_pRequestedPath(NULL)
+      , m_pVhostInfo(pVhostInfo)
 { 
     m_pContext = pContext;
     m_pContext->AddRef();
 
     m_pListenerMap = new CHXMapLongToObj;
+    HX_ADDREF(m_pVhostInfo);
 }
 
 /****************************************************************************
@@ -214,10 +216,25 @@
             {
                 char pTempString[256];
                 SafeSprintf(pTempString, 255, "RTPLive/%u: Failed to bind to the \
                port %d for activating %s. Port may be in use",
-                g_TLS_RTPProcNum, m_nLocalPort, m_pRequestedPath);
+                            g_TLS_RTPProcNum, m_nLocalPort, m_pRequestedPath);
                 pErrMsg->Report(HXLOG_ERR, HXR_FAIL, (ULONG32)HXR_FAIL, pTempString, \
NULL);  }
 
+            IHXBuffer*pBuf = NULL;
+            if( m_pVhostInfo && HXR_OK == \
m_pVhostInfo->GetPropertyBuffer("VhostAccount", pBuf) ) +            {
+                IHXErrorMessages2* pErrMsg2 = NULL; 
+                if (HXR_OK == m_pContext->QueryInterface(IID_IHXErrorMessages2, \
(void **)&pErrMsg2)) +                {
+                    char pTempString[256];
+                    SafeSprintf(pTempString, 255, "RTPLive/%u: Failed to bind to the \
port %d for activating %s. Port may be in use", +                            \
g_TLS_RTPProcNum, m_nLocalPort, m_pRequestedPath); +                    \
pErrMsg2->ReportByVhost(HXLOG_ERR, HXR_FAIL, (ULONG32)HXR_FAIL, pTempString, NULL, \
(const char*)pBuf->GetBuffer()); +                }
+                HX_RELEASE(pErrMsg2);
+            }
+            HX_RELEASE(pBuf);
+
             HX_RELEASE(pErrMsg);
         }
         else
@@ -352,6 +369,7 @@
     // reference, so don't worry about it too much.)
 
     m_pReceiverManager->ReceiverDone(m_ulLocalAddr, m_nLocalPort);
+    HX_RELEASE(m_pVhostInfo);
 }
 
 STDMETHODIMP


_______________________________________________
Server-cvs mailing list
Server-cvs@helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/server-cvs


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic