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

List:       helix-common-dev
Subject:    [Common-dev] RE: Changed common registry to work w/o context with
From:       "Eric Hyche" <ehyche () real ! com>
Date:       2009-02-18 15:11:58
Message-ID: 008601c991db$3f384f10$bda8ed30$ () com
[Download RAW message or body]

Sujeet,

IHXErrorMessages is usually implemented by the application and
not by the media platform. Also, it should not be an error
if a component is not able to obtain IHXErrorMessages from
its context.

Regarding IHXSapManager, all we have to do is add support
for creating CLSID_IHXSapManager in the encsession component
plugin. In other words, in client/encodesvc/engine/encsession/
encoding_service_plugin.cpp, we just need to add
CLSID_IHXSapManager to the list of objects that it can
provide and then in CHXEncodingServicePlugin::CreateComponentInstance
in the same file, add an "else if" clause for
CLSID_IHXSapManager where we do a "new CSapManager".

So I think option A is the way we should go, and I
think a half a day at the most should be required for it.

Eric

=======================================
Eric Hyche (ehyche@real.com)
Principal Engineer
RealNetworks, Inc.


>-----Original Message-----
>From: Sujeet Kharkar [mailto:skharkar@real.com]
>Sent: Tuesday, February 17, 2009 11:26 PM
>To: common-dev@helixcommunity.org
>Subject: CR: Changed common registry to work w/o context with HELIX_FEATURE_CLIENT defined.
>
>Synopsis
>============
>Fix crash in rembrdcst.
>Suggested Reviewer: Eric Hyche.
>
>Branches
>=========
>Head
>
>Description
>==============
>Rembrdcst library uses it's own context, if no context is passed to it.
>
>Producer is not passing context to rembrcst, in which case internal context
>loaded by rembrdcst which uses registry, which requires that context is
>available if HELIX_FEATURE_CLIENT is defined.
>Since Producer now has HELIX_FEATURE_CLIENT defined, this causes a crash.
>
>Possible Fixes:
>A> Use media platform as context and remove context from statically linking
>to rembrdcst.(At least ifdef it.)
>This will also involve adding support for IID_IHXSapManager and
>IID_IHXErrorMessages to media platform.
>
>Estimate: 2 days.
>
>B>
>Also check if new defined HELIX_NOT_USING_COMMON_CONTEXT is set, which will
>be set by producer.
>
>Due to less time I will log a bug to do A> and have implemented B for now.
>
>Files affected
>==================
>/cvsroot/common/util/commreg.cpp
>/cvsroot/common/util/asmrulep.cpp
>
>Testing
>=================
>Verified that rembrdcst does not crash.
>
>QA Hints
>=============
>Test various modes of rembrote broadcast.
>
>Diff
>=========
>
>Index: commreg.cpp
>===================================================================
>RCS file: /cvsroot/common/util/commreg.cpp,v
>retrieving revision 1.20
>diff -u -r1.20 commreg.cpp
>--- commreg.cpp	6 Jul 2007 20:39:16 -0000	1.20
>+++ commreg.cpp	18 Feb 2009 03:55:24 -0000
>@@ -2085,7 +2085,7 @@
> 		return CreateAndSetBufferCCF(prop_name,
>(UCHAR*)p->get_key_str(),
> 					     p->get_key_str_len(),
>m_pContext);
> 	    }
>-#ifndef HELIX_FEATURE_CLIENT
>+#if !defined(HELIX_FEATURE_CLIENT) ||
>defined(HELIX_NOT_USING_COMMON_CONTEXT)
> 	    prop_name = new CHXBuffer;
> 	    prop_name->Set((const unsigned char *)p->get_key_str(),
> 			   p->get_key_str_len());
>@@ -2318,7 +2318,7 @@
> 	CreateValuesCCF(pValues, m_pContext);
>     }
>     // Client should always provide m_pContext
>-#ifndef HELIX_FEATURE_CLIENT
>+#if !defined(HELIX_FEATURE_CLIENT) ||
>defined(HELIX_NOT_USING_COMMON_CONTEXT)
>     else
>     {
> 	pValues = new CHXHeader;
>
>Index: asmrulep.cpp
>===================================================================
>RCS file: /cvsroot/common/util/asmrulep.cpp,v
>retrieving revision 1.27
>diff -u -r1.27 asmrulep.cpp
>--- asmrulep.cpp	6 May 2008 18:45:27 -0000	1.27
>+++ asmrulep.cpp	18 Feb 2009 03:55:24 -0000
>@@ -1584,7 +1584,7 @@
> 				return HXR_OUTOFMEMORY;
> 			    }
> 			}
>-#ifndef HELIX_FEATURE_CLIENT
>+#if !defined(HELIX_FEATURE_CLIENT) ||
>defined(HELIX_NOT_USING_COMMON_CONTEXT)
> 			// Client should always provide m_pContext
> 			else
> 			{
>Index: commreg.cpp


_______________________________________________
Common-dev mailing list
Common-dev@helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/common-dev
[prev in list] [next in list] [prev in thread] [next in thread] 

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