Adam Martinson amartinson@codeweavers.com wrote:
- osver.dwOSVersionInfoSize = sizeof(osver);
- GetVersionExW(&osver);
...
- if (osver.dwMajorVersion >= 5)
Once again, that's wrong way of detecting win9x, or please try to explain better how the patch does what the subject describes, and for which app it's needed.
On 06/02/2011 03:10 PM, Dmitry Timoshkov wrote:
Adam Martinsonamartinson@codeweavers.com wrote:
- osver.dwOSVersionInfoSize = sizeof(osver);
- GetVersionExW(&osver);
...
- if (osver.dwMajorVersion>= 5)
Once again, that's wrong way of detecting win9x, or please try to explain better how the patch does what the subject describes, and for which app it's needed.
The stuff in that block is for win2k+ mode only. Win9x doesn't add [Total|Avail]Phys to [Total|Avail]PageFile. If wine is in win9x mode it should behave like win9x, or it confuses old apps. This is needed for the 2nd patch, IIRC removing the photoshop 4 hack in GlobalMemoryStatus() screws up programs like Adobe Illustrator 8 in win98 mode without it.
On 6/2/11 2:46 PM, Adam Martinson wrote:
On 06/02/2011 03:10 PM, Dmitry Timoshkov wrote:
Adam Martinsonamartinson@codeweavers.com wrote:
- osver.dwOSVersionInfoSize = sizeof(osver);
- GetVersionExW(&osver);
...
- if (osver.dwMajorVersion>= 5)
Once again, that's wrong way of detecting win9x, or please try to explain better how the patch does what the subject describes, and for which app it's needed.
The stuff in that block is for win2k+ mode only. Win9x doesn't add [Total|Avail]Phys to [Total|Avail]PageFile. If wine is in win9x mode it should behave like win9x, or it confuses old apps. This is needed for the 2nd patch, IIRC removing the photoshop 4 hack in GlobalMemoryStatus() screws up programs like Adobe Illustrator 8 in win98 mode without it.
I guess what Dmitry is really trying to ask is: what about NT4? Its major version is less than 5, but it's not a Win9x-family OS; it's an NT-family OS.
On 06/02/2011 09:21 PM, Charles Davis wrote:
On 6/2/11 2:46 PM, Adam Martinson wrote:
On 06/02/2011 03:10 PM, Dmitry Timoshkov wrote:
Adam Martinsonamartinson@codeweavers.com wrote:
- osver.dwOSVersionInfoSize = sizeof(osver);
- GetVersionExW(&osver);
...
- if (osver.dwMajorVersion>= 5)
Once again, that's wrong way of detecting win9x, or please try to explain better how the patch does what the subject describes, and for which app it's needed.
The stuff in that block is for win2k+ mode only. Win9x doesn't add [Total|Avail]Phys to [Total|Avail]PageFile. If wine is in win9x mode it should behave like win9x, or it confuses old apps. This is needed for the 2nd patch, IIRC removing the photoshop 4 hack in GlobalMemoryStatus() screws up programs like Adobe Illustrator 8 in win98 mode without it.
I guess what Dmitry is really trying to ask is: what about NT4? Its major version is less than 5, but it's not a Win9x-family OS; it's an NT-family OS.
Ah ok, so should be if ( osver.dwMajorVersion >= 5 || osver.dwPlatformId != VER_PLATFORM_WIN32_WINDOWS ).
Adam Martinson amartinson@codeweavers.com wrote:
The stuff in that block is for win2k+ mode only. Win9x doesn't add [Total|Avail]Phys to [Total|Avail]PageFile. If wine is in win9x mode it should behave like win9x, or it confuses old apps. This is needed for the 2nd patch, IIRC removing the photoshop 4 hack in GlobalMemoryStatus() screws up programs like Adobe Illustrator 8 in win98 mode without it.
You probably need to do what not Ex version does and merge both implementations.
On 06/03/2011 03:37 AM, Dmitry Timoshkov wrote:
Adam Martinsonamartinson@codeweavers.com wrote:
The stuff in that block is for win2k+ mode only. Win9x doesn't add [Total|Avail]Phys to [Total|Avail]PageFile. If wine is in win9x mode it should behave like win9x, or it confuses old apps. This is needed for the 2nd patch, IIRC removing the photoshop 4 hack in GlobalMemoryStatus() screws up programs like Adobe Illustrator 8 in win98 mode without it.
You probably need to do what not Ex version does and merge both implementations.
I don't think merging the implementations makes sense in this case, the only difference is 32-bit vs 64-bit output values. GlobalMemoryStatusEx() handles the basic behavior, GlobalMemoryStatus() handles rounding, I don't see a compelling reason to change that.