[Bug 50279] New: Registration free COM

WineHQ Bugzilla wine-bugs at winehq.org
Mon Dec 7 17:01:16 CST 2020


https://bugs.winehq.org/show_bug.cgi?id=50279

            Bug ID: 50279
           Summary: Registration free COM
           Product: Wine
           Version: 6.0-rc1
          Hardware: x86-64
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: ole32
          Assignee: wine-bugs at winehq.org
          Reporter: bvandermerwe at kbcat.com
      Distribution: ---

Created attachment 68829
  --> https://bugs.winehq.org/attachment.cgi?id=68829
Appx.exe.manifest

At first I thought wine does not support registration free COM, but according
to bug 25340 it does, and should be working. However, it does not work in some
situations.

Consider a 32 bit Windows application (composed of one small EXE and many
linked DLLs), which has the attached manifest file embedded via:

     mt.exe /manifest Appx.exe.manifest /outputresource:Appx.exe;#1

Now in the 32 bit application you have this C++ code:

hr = ::CoCreateInstance(CLSID_KCUnitop, NULL, CLSCTX_INPROC_SERVER,            
            IID_IKCUnitopSimulation, (void**)&m_pKCHunitopSimulation);

Then it fails saying the component is not registered. CLSID_KCUnitop comes
from:

MIDL_DEFINE_GUID(CLSID,
CLSID_KCUnitop,0xC4203DFD,0x03FA,0x11D3,0x9B,0xC7,0x00,0x50,0x04,0x09,0xFB,0x41);

This corresponds to the second comclass entry in the manifest file:

<file name="kcunitop.dll">
  <comClass clsid="{27345ECA-2B0E-11D3-BF76-0090271CC18F}"
threadingModel="Apartment"/>
  <comClass clsid="{C4203DFD-03FA-11D3-9BC7-00500409FB41}"
threadingModel="Apartment"/>
</file>

Registering the dll first using 'regsvr32 kcunitop.dll' does work around the
issue.

Sadly, I cannot provide the entire application. Perhaps the person who works on
this component can read through this and go "Ah we need to check for more than
one comClass entry" or "Oh you have curly brackets which we need to ignore" or
"Ah the #1 is causing it to not  find the manifest" or "The leading 0 is
causing isses".  (one can hope :-) )

I tried wine 5.0 onwards through 6.0 and the behavior is the same in all of
them.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list