Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-17707

MS Add/remove programs applet (appwiz.cpl) does not work in ReactOS

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Untriaged
    • Priority: Major
    • Resolution: Unresolved
    • Fix Version/s: None
    • Component/s: RosDlls, Shell
    • Labels:
      None
    • Environment:

      VirtualBox 5.1.38, reactos-bootcd-0.4.15-dev-2947-g59e1b78.

      Description

      Steps to reproduce the issue:

      1. Replace appwiz.cpl and duser.dll onto versions from XP/2003.
      2. Register appwiz.cpl via regsvr32 /i appwiz.cpl executed from Run dialog or Command Promt.
      3. Reboot.
      4. Now try to launch Add/remove programs from Control Panel or just directly from system32 directory.

      It will not start in both cases.
      When try to launch from Control Panel, visually will happen nothing, but if to use the cheked versions of appwiz.cpl and duser.dll, in the log appears some spam like this:

      err:(/dll/win32/ole32/compobj.c:2088) Mismatched CoUninitialize
      (/ntoskrnl/mm/ARM3/mdlsup.c:1076) MDL PROBE FAILED!
      fixme:(/dll/win32/dbghelp/module.c:1164) Wrong size
      (/dll/ntdll/ldr/ldrutils.c:1377) Overlapping DLL: C:\WINDOWS\System32\appwiz.cpl
      Assert @ .\resourcemanager.cpp, line 191:
      '(s_pthrSRT == 0)
      Destruction should reset s_pthrSRT'
      (/dll/ntdll/ldr/ldrinit.c:1027) WARNING: Exception 0x80000003 during LdrpCallInitRoutine(DLL_PROCESS_DETACH) for DUSER.dll
      

      For some reason happens an assert from duser, and due to this, it fails to load properly.
      But it happens definitely not due to dbghelp or ole32, because with XP/2K3 versions of them, nothing is changed.
      SeeĀ appwiz-do-window.log for details.

      When try to launch it from system32 by double-clicking instead, without Control Panel, appears the following crash:

      Unhandled exception
      ExceptionCode:    c0000005
      Faulting Address:        0
      CS:EIP 1b:73ebd730
      DS 23 ES 23 FS 3b GS 0
      EAX: 00000000   EBX: 00000000   ECX: 0022fc08
      EDX: 00000001   EBP: 0022fc60   ESI: 0023bfc0   ESP: 0022fc60
      EDI: 00000001   EFLAGS: 00010246
      Address:
      <appwiz.cpl:2d730> (C:\WINDOWS\system32\appwiz.cpl@73e90000)
      Frames:
      <shell32.dll:9e752> (C:\WINDOWS\system32\shell32.dll@7b020000)
      <rundll32.exe:17ef> (C:\WINDOWS\system32\rundll32.exe@400000)
      <rundll32.exe:2b0d> (C:\WINDOWS\system32\rundll32.exe@400000)
      <rundll32.exe:20b3> (C:\WINDOWS\system32\rundll32.exe@400000)
      <rundll32.exe:2108> (C:\WINDOWS\system32\rundll32.exe@400000)
      <kernel32.dll:11a42> (C:\WINDOWS\system32\kernel32.dll@7c5b0000)
      

      The most suspicious line is from shell32, and translating that address via raddr2line points to the following line: https://git.reactos.org/?p=reactos.git;a=blob;f=dll/win32/shell32/wine/control.c;h=9e8852c3a252bfa28a0d1e6a94afcf097e14c0ba;hb=HEAD#l854

      if (!applet->proc(applet->hWnd, CPL_STARTWPARMSW, sp, (LPARAM)extraPmts))
      

      See appwiz-do-launch.log for details.

      However, this cpl starts successfully when using our shell32.dll in Windows 2003 (after implementing SHGetShellStyleHInstance function, I will submit a PR ), at least when launching it from Control Panel. But it similarly fails when try to launch it from system32. So the crash in the 2nd case is indeed caused by our shell32, but the problem when it does not start even from Control Panel (in ReactOS), comes from something another. I don't know from where.
      I managed to reproduce this problem also in Wine Staging 5.19 by the way.

      As visible, my changes still don't fix the actual issue, although they much more improve the situation. Perhaps after fixing another preventing bug(s), this applet also may work in ReactOS.

        Attachments

        1. appwiz-do-launch.log
          71 kB
        2. appwiz-do-launch-crash.png
          appwiz-do-launch-crash.png
          63 kB
        3. appwiz-do-window.log
          100 kB
        4. MS-appwiz-after.png
          MS-appwiz-after.png
          47 kB
        5. MS-appwiz-before.png
          MS-appwiz-before.png
          79 kB

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              Oleg Dubinskij Oleg Dubinskiy
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: