(svn r14081) -Fix (r14075): WoW64 spoiled the 64 bits Windows detection and the installer for the 64 bits binary installed in the wrong directory. Thanks to michi_cc and glx for testing.
; Check whether we're not running an installer for 64 bits on 32 bits and vice versa
Function CheckProcessorArchitecture
cpudesc::tell
Pop $0 ;full identification string in $0
StrCpy $1 $0 2, 56 ;pull out the architecture
StrCmp $1 "00" 0 Win64
GetVersion::WindowsPlatformArchitecture
Pop $R0
IntCmp $R0 64 Win64 0
ClearErrors
IntCmp ${APPBITS} 64 0 Done
MessageBox MB_OKCANCEL|MB_ICONSTOP "You want to install the 64 bits OpenTTD on a 32 bits Operating System. This is not going to work. Please download the correct version. Do you really want to continue?" IDOK Done IDCANCEL Abort