PRB: AddPrintProcessor Fails to Install Processor DLL on Windows (242395)
The information in this article applies to:
- Microsoft Win32 Application Programming Interface (API), when used with:
- the operating system: Microsoft Windows 95
- the operating system: Microsoft Windows 98
- the operating system: Microsoft Windows 98 Second Edition
- the operating system: Microsoft Windows Millennium Edition
This article was previously published under Q242395 SYMPTOMS
A call to the AddPrintProcessor function to install a print processor dynamic link library (DLL) into the print spooler subsystem fails and returns FALSE. The GetLastError function returns the error value "ERROR_BAD_FORMAT". However, the DLL seems valid and can be loaded in a test application through a call to the LoadLibrary function. The problem may occur on some computers but not others.
CAUSE
The problem is caused by an attempt to relocate the DLL in memory when the LoadLibrary function is called by the spooler but the DLL was not linked to allow it to be relocated.
RESOLUTION
To resolve this problem, you can use the "/FIXED:no" linker option to build the DLL so it can be relocated in memory when the print spooler process attempts to load the executable file.
STATUSThis behavior is by design.
Modification Type: | Minor | Last Reviewed: | 5/3/2006 |
---|
Keywords: | kbDSWGDI2003Swept kbGDI kbprb kbSpooler KB242395 |
---|
|