Allegro.cc - Online Community

Allegro.cc Forums » Allegro Development » [A5] ex_menu crash after opening and closing a child

This thread is locked; no one can reply to it. rss feed Print
[A5] ex_menu crash after opening and closing a child
GullRaDriel
Member #3,861
September 2003
avatar

Here is the trace.

I can reproduce that each time.

#SelectExpand
1[New Thread 2212.0x1560] 2warning: HEAP[ex_menu.exe]: 3warning: HEAP: Free Heap block 2c44b00 modified at 2c44d20 after it was freed 4 5 6Program received signal SIGTRAP, Trace/breakpoint trap. 70x7729087d in ntdll!RtlpNtEnumerateSubKey () from C:\Windows\system32\ntdll.dll 8(gdb) where 9#0 0x7729087d in ntdll!RtlpNtEnumerateSubKey () from C:\Windows\system32\ntdll.dll 10#1 0x7724b2eb in ntdll!RtlUlonglongByteSwap () from C:\Windows\system32\ntdll.dll 11#2 0x02c44b00 in ?? () 12#3 0x771f3d1e in ntdll!RtlImageNtHeader () from C:\Windows\system32\ntdll.dll 13#4 0x77291123 in ntdll!RtlpNtEnumerateSubKey () from C:\Windows\system32\ntdll.dll 14#5 0x7724b146 in ntdll!RtlUlonglongByteSwap () from C:\Windows\system32\ntdll.dll 15#6 0x00b90000 in ?? () 16#7 0x771f3d1e in ntdll!RtlImageNtHeader () from C:\Windows\system32\ntdll.dll 17#8 0x764a9d45 in msvcrt!malloc () from C:\Windows\syswow64\msvcrt.dll 18#9 0x6be75968 in d3d_create_display_helper (w=w@entry=320, h=46418688, h@entry=240) at C:\Users\Gull\Downloads\allegro\src\win\d3d_disp.cpp:1558 19#10 0x6be76820 in d3d_create_display_locked (w=w@entry=320, h=h@entry=240) at C:\Users\Gull\Downloads\allegro\src\win\d3d_disp.cpp:1762 20#11 0x6be7703e in d3d_create_display (w=320, h=240) at C:\Users\Gull\Downloads\allegro\src\win\d3d_disp.cpp:1835 21#12 0x6be1d1e8 in al_create_display (w=320, h=240) at C:\Users\Gull\Downloads\allegro\src\display.c:53 22#13 0x00408dcf in main (argc=1, argv=0xb918a8) at C:\Users\Gull\Downloads\allegro\examples\ex_menu.c:184 23(gdb)

Line of ex_menu.c:184:
ALLEGRO_DISPLAY *d = al_create_display(320, 240);

"Code is like shit - it only smells if it is not yours"
Allegro Wiki, full of examples and articles !!

SiegeLord
Member #7,827
October 2006
avatar

Yeah, I looked a bit into this, but it seems pretty complex. Too bad there's no valgrind on Windows.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

Bruce Pascoe
Member #15,931
April 2015
avatar

MSVC does have that Application Verifier that does some of what valgrind does, but it's admittedly not as comprehensive and needs to be used in tandem with a debugger as it deliberately segfaults the app when an issue is encountered so you can diagnose it.

Go to: