https://bugs.documentfoundation.org/show_bug.cgi?id=158557

--- Comment #2 from Robert Goodman <[email protected]> ---
When I run the LibreOffice code (compiled using Dev Studio 2019), it
immediately destroys and unregisters the classes.. It winds up here:

Lines 74- 81 servproc.cxx

EmbedServer_Impl::~EmbedServer_Impl()
{
    for( int nInd = 0; nInd < SUPPORTED_FACTORIES_NUM; nInd++ )
    {
        if ( m_pOLEFactories[nInd] )
            m_pOLEFactories[nInd]->deregisterClass();
    }
}

Lines 128 - 133

bool EmbedProviderFactory_Impl::deregisterClass()
{
    HRESULT hresult = CoRevokeClassObject( m_factoryHandle );

    return (hresult == NOERROR);
}

CoRevokeClassObject removes the listener so COM doesn't work.. This code never
gets called again so COM is essentially broken.

I tried my code using the current OpenOffice build and it works... but I can't
find where the difference between OpenOffice code and LibreOffice code is in
this area.

Unfortunately my code is embedded in a larger program but it essentially comes
down to:

hResult = CoCreateInstance(
                        ClassId,
                        0,
                       CLSCTX_LOCAL_SERVER ,
                       IID_IUnknown,                                            
                       (VOID**)&pUnknown );

where ClassId is equal to your OID_WriterOASISTextServer. My code times out and
returns an error.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to