[bt-devel] Bt Windows Crash

Jaak Ristioja Ristioja at gmail.com
Sat Aug 7 12:46:20 MST 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 04.08.2010 05:10, Gary Holmlund wrote:
> //**************************************************
> DisplayOptions getDisplayOptionDefaults() {
> 00290D70  push        ebp
> 00290D71  mov         ebp,esp
> 00290D73  sub         esp,48h
> 00290D76  push        ebx
> 00290D77  push        esi
> 00290D78  push        edi
>     DisplayOptions options;
>     options.lineBreaks   = get(lineBreaks);
> 00290D79  push        0Ah
> 00290D7B  call        CBTConfig::get (2470F4h)
> 00290D80  add         esp,4
> 00290D83  movzx       eax,al
> 00290D86  mov         dword ptr [options],eax
>     options.verseNumbers = get(verseNumbers);
> 00290D89  push        0Bh
> 00290D8B  call        CBTConfig::get (2470F4h)
> 00290D90  add         esp,4
> 00290D93  movzx       eax,al
> 00290D96  mov         dword ptr [ebp-4],eax
>     return options;
> 00290D99  mov         eax,dword ptr [ebp+8]       // load EAX
> 00290D9C  mov         ecx,dword ptr [options]
> 00290D9F  mov         dword ptr [eax],ecx         // crash, registers before crash
> 00290DA1  mov         edx,dword ptr [ebp-4]
> 00290DA4  mov         dword ptr [eax+4],edx
> 00290DA7  mov         eax,dword ptr [ebp+8]
> }
> 
> // crash, registers before crash
> EAX = AD50DA3E EBX = 7EFDE000 ECX = 00000000 EDX = 031F0174 ESI = 0138F31C
> EDI = 03AF1A98 EIP = 00290D9F ESP = 0138F270 EBP = 0138F2C4 EFL = 00000212
> 
> Unhandled exception at 0x00290d9f in bibletime.exe: 0xC0000005:
> Access violation writing location 0xad50da3e.
> 
> So, the crash is because of a bad pointer in EAX. EAX is loaded from [ebp+8]. I think the
> problem is in the calling sequence, not the getDisplayOptionDefaults function. This
> function was called successfully once before this crash.  My assembly knowledge is not
> good enough for me to understand the calling sequence.

My assembly 5k1LLz are not that 1337 either, but isn't [ebp+8] usually the first argument
of a function in this calling convention? Hence I think this is invalid assembly.

Jaak
-----BEGIN PGP SI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