Skip to content

Commit

Permalink
dynamic_cast in editCurve, coverity issue 1075739, re #11151,
Browse files Browse the repository at this point in the history
  • Loading branch information
FedeMPouzols committed Feb 21, 2015
1 parent 796adda commit 9896620
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Code/Mantid/MantidPlot/src/PlotDialog.cpp
Expand Up @@ -356,7 +356,10 @@ void PlotDialog::editCurve()
return;

int index = item->plotItemIndex();
int curveType = dynamic_cast<PlotCurve *>(item->plotItem())->type();
PlotCurve* pc = dynamic_cast<PlotCurve *>(item->plotItem());
if (!pc)
return;
int curveType = pc->type();

hide();

Expand Down

0 comments on commit 9896620

Please sign in to comment.