[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: programs: Fix broken compilation on win64
From:       Maarten Lankhorst <maarten () codeweavers ! com>
Date:       2008-11-27 22:43:31
Message-ID: 492F2293.7050009 () codeweavers ! com
[Download RAW message or body]

Hi Rob,

Rob Shearman schreef:
> 2008/11/27 Maarten Lankhorst <maarten@codeweavers.com>:
>   
>> ---
>> Set the Spare[0] at runtime after a critical section is entered. :-)
>>
>> I'm not testing Spare[0] at all calls to EnterCriticalSection, but if this
>> is a problem I will send a revised patch
>>     
>
> IMHO, this is too fragile. My solution would be two macros: one for
> declaring a variable storing the name for a critical section, and a
> second for putting that name into the critical section structure. The
> latter would be something like the following for 64-bit:
> #define WINE_DEBUG_USE_CRIT_SECT_NAME(name)  { (DWORD)(DWORD_PTR)name,
> (DWORD)((DWORD_PTR)name >> 32) }
>
> It might even be better to let the macro fill in / declare the entire
> CRITICAL_SECTION_DEBUG stucture.
>   
If you can do that without compile errors you'll be my hero. I couldn't 
get that done, I tried..

Cheers,
Maarten.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic