OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
From: Krishnamoorthy, Meenakshisundaram (Meenakshisundaram.KrishnamoorthyKLA-TENCOR.COM)
Date: Tue Oct 02 2001 - 20:18:35 CDT

  • Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

    hi all,

    i've a strange problem. This is driving me nuts... !!!!!

    lemme explain the situation here.

    I've a component S which is an ATL based out-of-proc server i.e Server.exe.

    i've a client C living in process Client.exe, which calls a method on object
    S named pSomeInterfacetoS->GetComponentA(**ppSomeInterfacetoComponentA).

    The implementation of GetComponentA is shown below

    CSObj::GetComponentA(**ppSomeInterfaceteComponentA)
    {
      // create a loca server version of the object A.
     :: CoCreateInstance(...,CLSCTX_LOCAL_SERVER, ...);
    }

    Compoent A is a ATL based DLL server which is also registered for surrogate
    based activation (say using OLE View).

    The problem is the called to cocreateinstance of Component A in a local
    server throws an exception (accessviolation) sometimes, "ONLY SOMETIMES".

    Pl note that the exception is thrown only sometimes.

    i'm running W2000, SP2, VC++ 6.0, SP5, Platform SDK Nov2000.

    i downloaded the symbol files for W2000 SP2 and managed to get the call
    stack shown below at the point where the exception occurs.

    CAN SOMEBODY PL. TELL ME WHAT'S GOING ON..

    i'm out of ideas with no clues of what might be goin wrong...

    any pointers would be appreciated.

    thanks,

    mk

    OLE32! CCache::Flush(unsigned short) + 94 bytes
    OLE32! CCache::GetElement(unsigned long,unsigned char *,unsigned
    short,unsigned char *,unsigned short,unsigned short *,struct IUnknown * *) +
    260 bytes
    OLE32! CComCatalog::GetClassInfoW(struct IUserToken *,struct _GUID const
    &,struct _GUID const &,void * *,void *) + 92 bytes
    OLE32! CComCatalog::GetClassInfoW(struct _GUID const &,struct _GUID const
    &,void * *) + 29 bytes
    OLE32! GetClassInfoFromClsid(struct _GUID const &,struct IComClassInfo * *)
    + 33 bytes
    OLE32! GetActivationPropertiesIn36 <mailto:GetActivationPropertiesIn36> +
    249 bytes
    OLE32! ICoCreateInstanceEx(struct _GUID const &,struct IUnknown *,unsigned
    long,struct _COSERVERINFO *,unsigned long,unsigned long,struct tagMULTI_QI
    *,class ActivationPropertiesIn *) + 462 bytes
    OLE32! CoCreateInstanceEx24 <mailto:CoCreateInstanceEx24> + 40 bytes
    OLE32! CoCreateInstance20 <mailto:CoCreateInstance20> + 50 bytes
    IKTManagerImpl<CSObj>::GetObjectW(IKTManagerImpl<CSObj> * const 0x00bb54dc,
    unsigned long 4, IUnknown * * 0x00dcf794) line 47 + 33 bytes
    CSObj::GetComponentA(CSObj * const 0x00bb54c8, IKTCfgDataSpace * 0x0014d354,
    IKTSomeInterfacetoA * * 0x0017a490) line 229 + 29 bytes
    RPCRT4! Invoke12 <mailto:Invoke12> + 48 bytes
    RPCRT4! NdrStubCall216 <mailto:NdrStubCall216> + 1414 bytes
    RPCRT4! CStdStubBuffer_Invoke12 <mailto:CStdStubBuffer_Invoke12> + 158
    bytes
    OLEAUT32! CUnivStubWrapper::Invoke(struct tagRPCOLEMESSAGE *,struct
    IRpcChannelBuffer *) + 228 bytes
    OLE32! SyncStubInvoke(struct tagRPCOLEMESSAGE *,struct _GUID const &,class
    CIDObject *,struct IRpcChannelBuffer *,struct IRpcStubBuffer *,unsigned long
    *) + 94 bytes
    OLE32! StubInvoke(struct tagRPCOLEMESSAGE *,class CStdIdentity *,struct
    IRpcStubBuffer *,struct IRpcChannelBuffer *,struct tagIPIDEntry *,unsigned
    long *) + 129 bytes
    OLE32! CCtxComChnl::ContextInvoke(struct tagRPCOLEMESSAGE *,struct
    IRpcStubBuffer *,struct tagIPIDEntry *,unsigned long *) + 183 bytes
    OLE32! MTAInvoke(struct tagRPCOLEMESSAGE *,unsigned long,struct
    IRpcStubBuffer *,class IInternalChannelBuffer *,struct tagIPIDEntry
    *,unsigned long *) + 24 bytes
    OLE32! AppInvoke(class CMessageCall *,class CRpcChannelBuffer *,struct
    IRpcStubBuffer *,void *,void *,struct tagIPIDEntry *,struct LocalThis *) +
    123 bytes
    OLE32! ComInvokeWithLockAndIPID(class CMessageCall *,struct tagIPIDEntry *)
    + 538 bytes
    OLE32! ThreadInvoke(struct _RPC_MESSAGE *) + 316 bytes
    RPCRT4! DispatchToStubInC12 <mailto:DispatchToStubInC12> + 50 bytes
    RPCRT4! RPC_INTERFACE::DispatchToStubWorker(struct _RPC_MESSAGE *,unsigned
    int,long *) + 174 bytes
    RPCRT4! RPC_INTERFACE::DispatchToStub(struct _RPC_MESSAGE *,unsigned
    int,long *) + 68 bytes
    RPCRT4! RPC_INTERFACE::DispatchToStubWithObject(struct _RPC_MESSAGE *,class
    RPC_UUID *,unsigned int,long *) + 49 bytes
    RPCRT4! LRPC_SCALL::DealWithRequestMessage(void) + 147437 bytes
    RPCRT4! LRPC_ADDRESS::DealWithLRPCRequest(union _LRPC_MESSAGE *,union
    _LRPC_MESSAGE *,class LRPC_SASSOCIATION *,union _LRPC_MESSAGE * *) + 147
    bytes
    RPCRT4! LRPC_ADDRESS::ReceiveLotsaCalls(void) + 545 bytes
    RPCRT4! RecvLotsaCallsWrapper(class LRPC_ADDRESS *) + 9 bytes
    RPCRT4! BaseCachedThreadRoutine(class CACHED_THREAD *) + 72 bytes
    RPCRT4! ThreadStartRoutine(class THREAD *) + 24 bytes
    KERNEL32! BaseThreadStart8 <mailto:BaseThreadStart8> + 82 bytes

    ----------------------------------------------------------------
    Users Guide http://discuss.microsoft.com/archives/mailfaq.asp
    contains important info. Save time, search the archives at
    http://discuss.microsoft.com/archives/index.html .
    To unsubscribe, mailto:DCOM-signoff-requestDISCUSS.MICROSOFT.COM