News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Issue with vista

Started by Sean1337, March 21, 2008, 10:57:35 AM

Previous topic - Next topic

Sean1337

Hey all, having a problem with something that works on XP but seems to be very buggy on vista.

Here's the scenario:

- I have an application
- It calls LoadLibraryA 3 times to load 3 DLL's.
- On XP all 3 DLL's are loaded as I see the message boxes that I placed in each to verify that they were loaded.

- On vista the scenario is different. If one DLL is loaded, then the other two cannot be loaded and my application freezes.
- E.g. It calls LoadLibraryA for the first DLL and then when it goes to call LoadLibraryA for the second DLL it freezes. Or as another example, it doesn't call LoadLibraryA on the first DLL, calls LoadLibraryA on the 2nd DLL and then when it tries to call LoadLibraryA on the third DLL it freezes.

Does anyone have any insight as to why this might be happening?

If this helps, here's a code snippet:

Basically I have 3 calls to 3 functions that call LoadLibraryA:

call function1
call function2
call function3

each function contains the same code:

lea eax, [ebp-64] ;caption
lea ecx, [ebp-128] ;text

push MB_YESNO
push eax
push ecx
push 0
call MessageBoxA

.if (eax == 6) ;if user chooses YES on message box enter IF block

lea edx, [ebp-192] ;pointer to string that holds path of DLL
push edx
call LoadLibraryA

.endif

ret


To clarify the issue even more I'll tell you step by step what happens:

On XP:
- I double click application and the first function is called.
- When the first function is called I see the first YES NO message box. Yes = Load DLL, No = Do Not Load DLL
- I press YES on the first message box and the first DLL is loaded and a msgbox is shown to indicate that it is loaded
- I click ok on the loaded DLL's message box
- Now function2 gets called and a second YES NO message box is shown.
- I press YES and the second DLL gets loaded and the message box is shown.
- Same happens for the third DLL.

On Vista:
- I double click application and the first function is called.
- When the first function is called I see the first YES NO message box.
- I press YES and the first DLL is loaded
- Then i see second YES NO message box and I click YES.
- After I click yes the 2nd DLL is NOT loaded and the application freezes.

Hopefully you can help me resolve this!

Thanks,
-Sean