TLabel crahes with EXC_BAD_ACCESS
Original Reporter info from Mantis: accSone
-
Reporter name:
Original Reporter info from Mantis: accSone
- Reporter name:
Description:
compile with 64bit and TLable crashes in TWidgetSet.DrawText (intfbasewinapi.inc, line 750 ) when it tries to reset the DC brush in:
function TCocoaWidgetSet.SelectObject(ADC: HDC; GDIObj: HGDIOBJ): HGDIOBJ;
cocoawinapi.inc, line 1477
-> if gdi is TCocoaBrush then <- crashes here
Steps to reproduce:
Compile attached test program and run it.
Additional information:
Maybe the reason is a leak of the initial brushs and pens of the dc used by TLabel? No crash if one uncomment:
{Reset brush}
// SelectObject(DC, B);
{Reset pen}
// DeleteObject(SelectObject(DC, P));
in intfbasewinapi.inc, line 749
Mantis conversion info:
- Mantis ID: 25216
- OS: OSX
- OS Build: 10.6.8
- Build: 2013-10-18
- Platform: darwin x86_64
- Version: 1.3 (SVN)