Steema Issues Database

Note: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;
otherwise you can use StackOverflow.
Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy.



Bug 550

Summary: Acccess Violation GDI Plus Canvas
Product: VCL TeeChart Reporter: roth
Component: SeriesAssignee: Steema Issue Manager <issuemanager>
Status: RESOLVED WORKSFORME    
Severity: enhancement CC: narcis, sandra
Priority: ---    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows   
Chart Series: --- Delphi / C++ Builder RAD IDE Version:
Attachments: call stack

Description roth 2014-01-24 05:47:09 EST
Created attachment 77 [details]
call stack

Hi.

We recently receaved an Access Violation with the following call stack:

main thread ($111c):
7fefad3c gdiplus.dll
7fefac9e gdiplus.dll                           GdipFillRectangle
7fefac9e gdiplus.dll                           GdipFillRectangleI
00febb80 TreeSize.exe Winapi.GDIPOBJ           TGPGraphics.FillRectangle
00ff3bc9 TreeSize.exe TeeGDIPlus      1972  +8 TGDIPlusCanvas.Rectangle
00f5882f TreeSize.exe TeeProcs        4177 +22 InternalDrawShape
00f58fe2 TreeSize.exe TeeProcs        4296 +47 TTeeCustomShape.DrawRectRotated
00f585f1 TreeSize.exe TeeProcs        4147  +1 TTeeCustomShape.DrawRectRotated
00f77c70 TreeSize.exe TeEngine        7376 +28 TSeriesMarks.DrawItem
00f77e4b TreeSize.exe TeEngine        7413  +2 TSeriesMarks.InternalDraw
00f7f78a TreeSize.exe TeEngine       10475  +1 TChartSeries.DrawMark
00fbe873 TreeSize.exe Series          5830 +56 TBarSeries.DrawMark
00f7f67a TreeSize.exe TeEngine       10458 +23 TChartSeries.DrawMarks
00f86a83 TreeSize.exe TeEngine       13621 +10 DrawMarksSeries
00f879a4 TreeSize.exe TeEngine       13765 +89 DrawSeries
00f87b01 TreeSize.exe TeEngine       13783  +5 DoDraw
00f87cfb TreeSize.exe TeEngine       13811  +8 DrawAllSeries
00f87df3 TreeSize.exe TeEngine       13833 +15 TCustomAxisPanel.DrawAxesSeries
00f86676 TreeSize.exe TeEngine       13535 +47 TCustomAxisPanel.InternalDraw
00f54186 TreeSize.exe TeeProcs        1886 +22 TCustomTeePanel.Draw
00f53a5e TreeSize.exe TeeProcs        1794 +19 TCustomTeePanel.Draw
00f5422f TreeSize.exe TeeProcs        1924 +11 TCustomTeePanel.Paint
005bf2a6 TreeSize.exe Vcl.Controls             TCustomControl.PaintWindow
005b6613 TreeSize.exe Vcl.Controls             TWinControl.PaintHandler
005b741f TreeSize.exe Vcl.Controls             TWinControl.WMPaint
005bf238 TreeSize.exe Vcl.Controls             TCustomControl.WMPaint
0040a79e TreeSize.exe System                   TObject.Dispatch
005af193 TreeSize.exe Vcl.Controls             TControl.WndProc
005b6393 TreeSize.exe Vcl.Controls             TWinControl.WndProc
00f54966 TreeSize.exe TeeProcs        2234  +4 TCustomTeePanel.WndProc
005b5607 TreeSize.exe Vcl.Controls             TWinControl.MainWndProc
004d4d23 TreeSize.exe System.Classes           StdWndProc
774a11f1 ntdll.dll                             KiUserCallbackDispatcher
77246e67 USER32.dll                            DispatchMessageW
007200bf TreeSize.exe Vcl.Forms                TApplication.ProcessMessage
00720133 TreeSize.exe Vcl.Forms                TApplication.HandleMessage
0072062f TreeSize.exe Vcl.Forms                TApplication.Run
012591c6 TreeSize.exe TreeSize          93 +37 initialization
7734709f kernel32.dll                          LoadLibraryA

The complete file can be found attached.

Please note: This is a 64 bit application compiled with Delphi XE2!

We do not have a repro for this but I wonder if you have seen such an issue before and if this might have been fixed in the meantime?

Thank you and best regards!
Comment 1 sandra pazos 2014-01-24 10:05:08 EST
Hello roth,

Thanks for your information. I would be very grateful, if you can arrange for us a simple project where your problem occurs, so we can reproduce the problem here and try to solve it. 

Thanks in advance,
Comment 2 roth 2014-01-24 10:21:22 EST
Hi.

As I mentioned, I am not able to reproduce this issue, nor create a sample project where this issue occurs.

I know that it is hard to resolve a bug without a usable repro or sample project.

It would be great if one of your developers could take a look at the call stack and check the source code if they might have an idea why this happens.

Just an idea: Since this was a 64 bit application where this access violation occurred it the reason for this issue might be an invalid Pointer casting at some point in the code. 
Please note: Size of Pointer in a 64 bit applications is 8, in a 32 application is 4. This could lead to issues when casting Integer (always size 4) to Pointer.
Developers have to take care using NativeInt instead of Integer when used for explicit casting to Pointer.

I hope this helps!
Comment 3 narcís calvet 2014-01-24 10:31:13 EST
Hello,

Many apologies for the confusion. With which TeeChart build did this occur? As I told at the support forums(http://www.teechart.net/support/viewtopic.php?f=3&t=14361&p=63590&#p63590), we fixed similar issues for the latest 2013.09.131119 build. We can also provide a test version with our current sources to check if it solves the problem at your end.

Thanks in advance.
Comment 4 roth 2014-01-24 10:39:46 EST
A test version would be highly appreciated!

Even though I cannot tell you if this new "test" version fixes the issue (since I have no repro), but I could check if some other issues are resolved.

Thank you!
Comment 5 narcís calvet 2014-01-24 10:51:20 EST
Sure, sent it a few minutes ago. A few instances of the NativeInt casting issue were fixed for 2013.09.13119. Feel free to let us know of any other issue you come across.