|Anonymous | Login | Signup for a new account||2019-04-26 04:48 CEST|
|Main | My View | View Issues | Change Log | Roadmap | Docs|
|Viewing Issue Simple Details|
|ID||Category||Severity||Reproducibility||Date Submitted||Last Update|
|0003879||[JEDI VCL] 00 JVCL Components||crash||always||2006-08-30 05:00||2006-08-30 07:23|
|Status||resolved||Product Version||Daily / GIT|
|Summary||0003879: TJvTabBar is broken in the latest SVN snapshot|
|Description||If you have a TJvTabBar on the form and it contains at least one tab, you will experience a crash (access violation) as soon as you try to close/destroy the form. I've tested this with daily SVN JCL/JVCL build (both are dated 2006-08-29).|
I have debugged this problem and came to the following conclusion:
1. When TJvTabBar is being destroyed, it tries to free the internal tab item collection it holds by calling "FreeAndNil(FTabs);" in the TJvTabBar.Destroy method.
2. This in turn causes a series of method calls to occur, namely invoking the destructor of FTabs collection which in turn tries to remove the items one by one.
3. The next method called in this chain is TJvTabBarItems.Notification which contains the following code snippet:
if TabBar.LeftTab = Item then
TabBar.LeftTab := TabBar.LeftTab.GetPreviousVisible;
The problem occurs while accessing the LeftTab property of TabBar because the getter method GetLeftTab tries to access the FTabs.Count property but since the TJvTabBar destructor uses FreeAndNil to free the tabs collection, the private field FTabs is already NILLED at this time, this is why the AV occurs.
Proposed fix: Replace this line in TJvTabBar.Destroy method:
by this one:
I've recompiled the JVCL installation on my machine and the problem no longer occurs. So I'd say this fix works just fine for me.
|Tags||No tags attached.|
|2006-08-30 05:00||ivobauer||New Issue|
|2006-08-30 05:01||ivobauer||Issue Monitored: ivobauer|
|2006-08-30 07:23||obones||Status||new => resolved|
|2006-08-30 07:23||obones||Fixed in Version||=> Daily / SVN|
|2006-08-30 07:23||obones||Resolution||open => fixed|
|2006-08-30 07:23||obones||Assigned To||=> obones|
|2006-08-30 07:23||obones||Note Added: 0010035|
|Mantis 1.1.6[^] Copyright © 2000 - 2008 Mantis Group|