FIX: General Protection Fault When .FLL Is Loaded TwiceLast reviewed: October 20, 1997Article ID: Q120182 |
2.5x 2.6x
WINDOWS
kbenv kbfixlist kbbuglist kberrmsg
The information in this article applies to:
SYMPTOMSWhen you attempt to load an .FLL file, the second load causes the following general protection (GP) fault error message:
FoxProW caused a General Protection Fault in module KRNL386.EXE at xxxx:xxxx CAUSEThis problem will occur if WIN87EM.DLL has not been loaded properly.
RESOLUTIONMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem was corrected in Visual FoxPro 3.0 for Windows.
WORKAROUNDTo avoid this problem, do the following:
MORE INFORMATIONWIN87EM.DLL is the library used to support floating-point emulation in Windows-based applications. This problem occurs under the following conditions:
After the FLL is loaded the first time, the task database contains a valid code pointer (valid selector). When the application unloads the FLL (but the application does not exit), the code pointer remains in the task database because the startup code for the FLL does not call fpterm. When the FLL is unloaded, WIN87EM.DLL is also unloaded. Loading the FLL again at this point will repeat the process of installing the exception handler and reading the "old" handler. The old handler this time is not NULL but rather a pointer to a function in WIN87EM where WIN87EM used to be before it was unloaded from memory the first time. This results in a bad selector load, which causes the GP fault. In addition, if a long time has elapsed between the two times the FLL was loaded, the selector may have been "reused" for something else, causing unpredictable results for the FoxPro application. The first time FoxPro GP faults, it leaves WIN87EM stranded in memory. The problem only occurs if WIN87EM is also loaded and unloaded with the FLL.
|
Additional reference words: VFoxWin FoxWin 2.50 2.50a 2.50b 2.60 2.60a LCK
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |