Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0030784Open CASCADE[OCCT] OCCT:Visualizationpublic2019-06-17 13:122019-06-17 13:33
Assigned Tonds 
PlatformOSOS Version
Product Version 
Target Version[OCCT] 7.4.0*Fixed in Version 
Summary0030784: Visualization - check if selectable of owner in internal container in AIS_InteractiveContext before using
DescriptionIn some methods of interactive context global status of interactive object is obtained from myObjects without a check if the object is registered inside.

Example of crash, cased by it:
In AIS_ViewCube implementation (0028954) there is AIS_ViewCubeFlat not displayed in context, but there is an owner connected to it and listening selection.

The place, where the crash happens if we call it for this owner:
void AIS_InteractiveContext::AddOrRemoveSelected (const Handle(SelectMgr_EntityOwner)& theOwner, ...
  const Handle(AIS_InteractiveObject) anObj = Handle(AIS_InteractiveObject)::DownCast (theOwner->Selectable());
  Handle(AIS_GlobalStatus)& aStatus = myObjects.ChangeFind (anObj);
TagsNo tags attached.
Test case number
Attached Files

- Relationships

-  Notes
git (administrator)
2019-06-17 13:27

Branch CR30784 has been created by nds.

SHA-1: a52908d650245f4930cf42fafe545e15c10f3aa6

Detailed log of new commits:

Author: nds
Date: Tue May 14 14:31:43 2019 +0300

    0030784: Visualization - check if selectable of owner in internal container in AIS_InteractiveContext before using
    # todo - add similar check for other places where needed
kgv (developer)
2019-06-17 13:33

     const Handle(AIS_InteractiveObject) anObj = Handle(AIS_InteractiveObject)::DownCast (theOwner->Selectable());

+    if (!myObjects.IsBound(anObj))
+      return;
     const Standard_Boolean isGlobal = anObj->GlobalSelOwner() == theOwner;
     Handle(AIS_GlobalStatus)& aStatus = myObjects.ChangeFind (anObj);


- Issue History
Date Modified Username Field Change
2019-06-17 13:12 nds New Issue
2019-06-17 13:12 nds Assigned To => kgv
2019-06-17 13:27 git Note Added: 0085088
2019-06-17 13:28 nds Assigned To kgv => nds
2019-06-17 13:33 kgv Note Added: 0085089

Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker