http://bugs.winehq.org/show_bug.cgi?id=30665
Bug #: 30665 Summary: Add support for DeletePrinterDriverEx deletion flags (DPD_DELETE_*) Product: Wine Version: 1.5.4 Platform: x86 OS/Version: Linux Status: NEW Severity: enhancement Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: focht@gmx.net Classification: Unclassified
Hello,
encountered this with "Acrobat 7" tryout installer.
The installer executes a custom action "DeleteDistillerPrinter" to remove any previous remains of "Adobe PDF Converter" driver.
DPD_DELETE_UNUSED_FILES 0x00000001 DPD_DELETE_SPECIFIC_VERSION 0x00000002 DPD_DELETE_ALL_FILES 0x00000004
First try (DPD_DELETE_UNUSED_FILES | DPD_DELETE_ALL_FILES):
--- snip --- 0025:trace:msi:HANDLE_CustomType1 Calling function L"DeleteDistillerPrinter" from L"C:\users\focht\Temp\msiba95.tmp" ... 0037:trace:msi:ACTION_CallDllFunction calling L"DeleteDistillerPrinter" ... 0037:Call KERNEL32.LoadLibraryA(004d9d1c "winspool.drv") ret=004d4c0e 0037:Ret KERNEL32.LoadLibraryA() retval=f7460000 ret=004d4c0e 0037:Call KERNEL32.GetProcAddress(f7460000,004d9d04 "DeletePrinterDriverExA") ret=004d4c2a 0037:Ret KERNEL32.GetProcAddress() retval=f74653e4 ret=004d4c2a 0037:Call winspool.drv.DeletePrinterDriverExA(00000000,00000000,004d9844 "Adobe PDF Converter",00000005,00000000) ret=004d4c36 0037:Call ntdll.RtlCreateUnicodeStringFromAsciiz(015be704,004d9844 "Adobe PDF Converter") ret=f74663b7 0037:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f74663b7 0037:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 5 0 0037:fixme:winspool:DeletePrinterDriverExW dwDeleteFlag = 5 - unsupported ... 0037:Ret winspool.drv.DeletePrinterDriverExA() retval=00000000 ret=004d4c36 0037:Call KERNEL32.FreeLibrary(f7460000) ret=004d4c44 0037:Ret KERNEL32.FreeLibrary() retval=00000001 ret=004d4c44 ... --- snip ---
Second try (DPD_DELETE_UNUSED_FILES):
--- snip --- 0037:Call winspool.drv.DeletePrinterDriverExA(00000000,00000000,004d9844 "Adobe PDF Converter",00000001,00000000) ret=004d4c52 0037:Call ntdll.RtlCreateUnicodeStringFromAsciiz(015be714,004d9844 "Adobe PDF Converter") ret=f74663b7 0037:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f74663b7 0037:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 1 0 0037:fixme:winspool:DeletePrinterDriverExW dwDeleteFlag = 1 - unsupported ... 0037:Ret winspool.drv.DeletePrinterDriverExA() retval=00000000 ret=004d4c52 --- snip ---
Third try, "fallback" (empty deletion flags):
--- snip --- 0037:Call winspool.drv.DeletePrinterDriverA(00000000,00000000,004d9844 "Adobe PDF Converter") ret=004d4c65 0037:Call ntdll.RtlCreateUnicodeStringFromAsciiz(015be704,004d9844 "Adobe PDF Converter") ret=f74663b7 0037:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f74663b7 0037:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 0 0 0037:trace:winspool:WINSPOOL_OpenDriverReg ((null)) 0037:trace:winspool:validate_envW testing (null) ... 0037:trace:winspool:validate_envW using 0xf748902c: L"Windows NT x86" ... 0037:Call advapi32.RegCreateKeyW(80000002,00d85ae8 L"System\CurrentControlSet\control\Print\Environments\Windows NT x86\Drivers\Version-3",015be634) ret=f746ebca 0037:Ret advapi32.RegCreateKeyW() retval=00000000 ret=f746ebca 0037:Call ntdll.RtlFreeHeap(00110000,00000000,00d85ae8) ret=f746ebf4 0037:Ret ntdll.RtlFreeHeap() retval=00000001 ret=f746ebf4 0037:Call advapi32.RegDeleteTreeW(00000104,00d85ab8 L"Adobe PDF Converter") ret=f747c98a 0037:Ret advapi32.RegDeleteTreeW() retval=00000002 ret=f747c98a 0037:Call advapi32.RegCloseKey(00000104) ret=f747c9a3 0037:Ret advapi32.RegCloseKey() retval=00000000 ret=f747c9a3 ... 0037:Ret winspool.drv.DeletePrinterDriverA() retval=00000000 ret=004d4c65 --- snip ---
MSDN: http://msdn.microsoft.com/en-us/library/windows/desktop/dd183546%28v=vs.85%2...
--- quote --- dwDeleteFlag [in]
The options for deleting files and versions of the driver. This parameter can be one or more of the following values. Value Meaning
DPD_DELETE_SPECIFIC_VERSION
Deletes the version specified in dwVersionFlag. This does not ensure that the driver will be removed from the list of supported drivers for the server.
DPD_DELETE_UNUSED_FILES
Removes any unused driver files.
DPD_DELETE_ALL_FILES
Deletes the driver only if all its associated files can be removed. The delete operation fails if any of the driver's files are being used by some other installed driver.
If DPD_DELETE_SPECIFIC_VERSION is not specified, the function deletes all versions of the driver if none of them is in use. If neither DPD_DELETE_UNUSED_FILES nor DPD_DELETE_ALL_FILES is specified, the function does not delete driver files. --- quote ---
Source:
http://source.winehq.org/git/wine.git/blob/7508a5d4b2d5246ea9c19afd734274d12...
--- snip --- 6626 BOOL WINAPI DeletePrinterDriverExW( LPWSTR pName, LPWSTR pEnvironment, 6627 LPWSTR pDriverName, DWORD dwDeleteFlag, DWORD dwVersionFlag) 6628 { 6629 HKEY hkey_drivers; 6630 BOOL ret = FALSE; 6631 6632 TRACE("%s %s %s %x %x\n", debugstr_w(pName), debugstr_w(pEnvironment), 6633 debugstr_w(pDriverName), dwDeleteFlag, dwVersionFlag); 6634 6635 if(pName && pName[0]) 6636 { 6637 FIXME("pName = %s - unsupported\n", debugstr_w(pName)); 6638 SetLastError(ERROR_INVALID_PARAMETER); 6639 return FALSE; 6640 } 6641 6642 if(dwDeleteFlag) 6643 { 6644 FIXME("dwDeleteFlag = %x - unsupported\n", dwDeleteFlag); 6645 SetLastError(ERROR_INVALID_PARAMETER); 6646 return FALSE; 6647 } ... 6662 return ret; 6663 } --- snip ---
There is a page fault after the last call to winspool.drv.DeletePrinterDriverA() which might be a separate bug.
--- snip --- 0037:trace:seh:raise_exception code=c0000005 flags=0 addr=0x7bc78e63 ip=7bc78e63 tid=0037 0037:trace:seh:raise_exception info[0]=00000000 0037:trace:seh:raise_exception info[1]=00000000 0037:trace:seh:raise_exception eax=00000000 ebx=7bcbf544 ecx=75e74639 edx=00000000 esi=7ed94da0 edi=00000037 0037:trace:seh:raise_exception ebp=015be478 esp=015be380 cs=0023 ds=002b es=002b fs=0063 gs=006b flags=00010246 0037:trace:seh:call_stack_handlers calling handler at 0x7bc91c09 code=c0000005 flags=0 0037:trace:seh:__regs_RtlUnwind code=c0000005 flags=2 0037:trace:seh:__regs_RtlUnwind calling handler at 0x7bc76e57 code=c0000005 flags=2 0037:trace:seh:__regs_RtlUnwind handler at 0x7bc76e57 returned 1 0037:trace:seh:raise_exception code=c0000005 flags=0 addr=(nil) ip=00000000 tid=0037 0037:trace:seh:raise_exception info[0]=00000000 0037:trace:seh:raise_exception info[1]=00000000 0037:trace:seh:raise_exception eax=00000000 ebx=7ed46639 ecx=00000000 edx=00000004 esi=7ed94da0 edi=00000037 0037:trace:seh:raise_exception ebp=004d4c65 esp=015be7ec cs=0023 ds=002b es=002b fs=0063 gs=006b flags=00010202 ... 0037:err:msi:ACTION_CallDllFunction Custom action (L"C:\users\focht\Temp\msiba95.tmp":L"DeleteDistillerPrinter") caused a page fault: c0000005 --- snip ---
$ du -sh AcTR7EFG.exe 116M AcTR7EFG.exe
$ sha1sum AcTR7EFG.exe 4f1ff389ea71f21d624083d65bbe5a74e4760079 AcTR7EFG.exe
Regards
http://bugs.winehq.org/show_bug.cgi?id=30665
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, Installer URL| |http://ardownload.adobe.com | |/pub/adobe/acrobat/win/7x/7 | |.0/misc/AcTR7EFG.exe
http://bugs.winehq.org/show_bug.cgi?id=30665
Detlef Riekenberg wine.dev@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |wine.dev@web.de
https://bugs.winehq.org/show_bug.cgi?id=30665
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Add support for |Acrobat 7 installer wants |DeletePrinterDriverEx |support for |deletion flags |DeletePrinterDriverEx |(DPD_DELETE_*) |deletion flags | |(DPD_DELETE_*)
--- Comment #1 from Anastasius Focht focht@gmx.net --- Hello folks,
revisiting, still present.
--- snip --- ... 002b:trace:msi:HANDLE_CustomType1 Calling function L"DeleteDistillerPrinter" from L"C:\users\focht\Temp\msi54f.tmp" ... 0047:trace:msi:ACTION_CallDllFunction calling L"DeleteDistillerPrinter" ... 0047:Call winspool.drv.DeletePrinterDriverExA(00000000,00000000,00b89844 "Adobe PDF Converter",00000005,00000000) ret=00b84c36 0047:Call ntdll.RtlCreateUnicodeStringFromAsciiz(00ede774,00b89844 "Adobe PDF Converter") ret=f6f3b7b2 0047:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f6f3b7b2 0047:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 5 0 0047:fixme:winspool:DeletePrinterDriverExW dwDeleteFlag = 5 - unsupported ... 0047:Ret winspool.drv.DeletePrinterDriverExA() retval=00000000 ret=00b84c36 ... 0047:Call winspool.drv.DeletePrinterDriverExA(00000000,00000000,00b89844 "Adobe PDF Converter",00000001,00000000) ret=00b84c52 0047:Call ntdll.RtlCreateUnicodeStringFromAsciiz(00ede784,00b89844 "Adobe PDF Converter") ret=f6f3b7b2 0047:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f6f3b7b2 0047:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 1 0 0047:fixme:winspool:DeletePrinterDriverExW dwDeleteFlag = 1 - unsupported ... 0047:Ret winspool.drv.DeletePrinterDriverExA() retval=00000000 ret=00b84c52 0047:Call winspool.drv.DeletePrinterDriverA(00000000,00000000,00b89844 "Adobe PDF Converter") ret=00b84c65 0047:Call ntdll.RtlCreateUnicodeStringFromAsciiz(00ede764,00b89844 "Adobe PDF Converter") ret=f6f3b7b2 0047:Ret ntdll.RtlCreateUnicodeStringFromAsciiz() retval=00000001 ret=f6f3b7b2 0047:trace:winspool:DeletePrinterDriverExW (null) (null) L"Adobe PDF Converter" 0 0 0047:trace:winspool:WINSPOOL_OpenDriverReg ((null)) 0047:trace:winspool:validate_envW testing (null) ... 0047:trace:winspool:validate_envW using 0xf6f61eb8: L"Windows NT x86" ... 0047:Call advapi32.RegCreateKeyW(80000002,01db2fd8 L"System\CurrentControlSet\control\Print\Environments\Windows NT x86\Drivers\Version-3",00ede684) ret=f6f45d62 0047:Ret advapi32.RegCreateKeyW() retval=00000000 ret=f6f45d62 ... 0047:Call advapi32.RegDeleteTreeW(000000e4,01db2fa8 L"Adobe PDF Converter") ret=f6f53c0f 0047:Ret advapi32.RegDeleteTreeW() retval=00000002 ret=f6f53c0f 0047:Call advapi32.RegCloseKey(000000e4) ret=f6f53c28 0047:Ret advapi32.RegCloseKey() retval=00000000 ret=f6f53c28 ... 0047:Ret winspool.drv.DeletePrinterDriverA() retval=00000000 ret=00b84c65 0047:trace:seh:raise_exception code=c0000005 flags=0 addr=(nil) ip=00000000 tid=0047 0047:trace:seh:raise_exception info[0]=00000000 0047:trace:seh:raise_exception info[1]=00000000 0047:trace:seh:raise_exception eax=00000000 ebx=7bc3b4e9 ecx=009c59f8 edx=00000004 esi=7edac000 edi=00edfb40 0047:trace:seh:raise_exception ebp=00b84c65 esp=00ede82c cs=0023 ds=002b es=002b fs=0063 gs=006b flags=00210206 0047:trace:seh:call_stack_handlers calling handler at 0x7ed4a03f code=c0000005 flags=0 ... 0047:err:msi:ACTION_CallDllFunction Custom action (L"C:\users\focht\Temp\msi54f.tmp":L"DeleteDistillerPrinter") caused a page fault: c0000005 --- snip ---
$ wine --version wine-1.7.24-150-gcf4404c
Regards
https://bugs.winehq.org/show_bug.cgi?id=30665
Ken Sharp imwellcushtymelike@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Severity|enhancement |minor
https://bugs.winehq.org/show_bug.cgi?id=30665
super_man@post.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |super_man@post.com
--- Comment #2 from super_man@post.com --- It's still an issue. I made a patch that translates the flags into human readable form, but doesn't really do anything. Also the crash mentioned here is still valid issue I tried to dig into that too, but I couldn't figure out so far what's the cause.
wine 1.7.51
https://bugs.winehq.org/show_bug.cgi?id=30665
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|-unknown |spooler
--- Comment #3 from Anastasius Focht focht@gmx.net --- Hello folks,
revisiting, still present.
https://source.winehq.org/git/wine.git/blob/HEAD:/dlls/winspool.drv/info.c#l...
$ sha1sum AcTR7EFG.exe 4f1ff389ea71f21d624083d65bbe5a74e4760079 AcTR7EFG.exe
$ du -sh AcTR7EFG.exe 116M AcTR7EFG.exe
$ wine --version wine-4.3
Regards
https://bugs.winehq.org/show_bug.cgi?id=30665
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- URL|http://ardownload.adobe.com |https://web.archive.org/web |/pub/adobe/acrobat/win/7x/7 |/20140209233532/http://ardo |.0/misc/AcTR7EFG.exe |wnload.adobe.com/pub/adobe/ | |acrobat/win/7x/7.0/misc/AcT | |R7EFG.exe
--- Comment #4 from Anastasius Focht focht@gmx.net --- Hello folks,
revisiting, still present.
Adding stable link via Internet Archive:
https://web.archive.org/web/20140209233532/http://ardownload.adobe.com/pub/a...
$ wine --version wine-5.9
Regards
https://bugs.winehq.org/show_bug.cgi?id=30665
--- Comment #5 from Anastasius Focht focht@gmx.net --- Hello folks,
revisiting, still present.
https://source.winehq.org/git/wine.git/blob/HEAD:/dlls/winspool.drv/info.c#l...
$ wine --version wine-7.0-119-gc09a5da1575
Regards
https://bugs.winehq.org/show_bug.cgi?id=30665
Neko-san nekoNexus@protonmail.ch changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nekoNexus@protonmail.ch