Modify

#2293 closed Bug (No Bug)

_GDIPlus_GraphicsDrawImage crashes if we dispose the bitmap.

Reported by: anonymous Owned by:
Milestone: Component: Standard UDFs
Version: 3.3.8.1 Severity: None
Keywords: Cc:

Description

$hGUI = GUICreate("GDI+")
GUISetState()

_GDIPlus_Startup()
$hGraphic = _GDIPlus_GraphicsCreateFromHWND($hGUI)
$hbitmap1 = _GDIPlus_BitmapCreateFromGraphics(100, 100, $hGraphic)

_GDIPlus_BitmapDispose($hbitmap1);*
ConsoleWrite('the crach will came now'&@CRLF)
_GDIPlus_GraphicsDrawImage($hGraphic, $hbitmap1, 0, 0)
ConsoleWrite('If you see this message, it s ok'&@CRLF)

Attachments (0)

Change History (1)

comment:1 by trancexx, on Dec 22, 2012 at 10:30:25 AM

Resolution: No Bug
Status: newclosed

So you are disposing image object and then use pointer to released object to draw. Then you report bug because of the crash you get.
...I'm sorry for you waiting 4 days for developer (OMG!) response and for AutoIt not having one person with enough knowledge and capability to close this report earlier. Clearly we are doing something wrong.
I'm also sure that some time from now you will say for yourself: "Oh that was embarrassing, shame on me."

Btw, Your code is unrunnable.

Modify Ticket

Action
as closed The ticket will remain with no owner.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.