Added a validity check in SIM_PLOT_PANEL::IsGridShown()

Fixes: lp:1712086
* https://bugs.launchpad.net/kicad/+bug/1712086
This commit is contained in:
Christian Jacobsen 2017-12-18 09:33:05 +01:00 committed by Maciej Suminski
parent 9413793ef4
commit ff4829eee6
1 changed files with 3 additions and 0 deletions

View File

@ -224,6 +224,9 @@ public:
bool IsGridShown() const
{
if( !m_axis_x || !m_axis_y1 )
return false;
assert( m_axis_x->GetTicks() == m_axis_y1->GetTicks() );
return !m_axis_x->GetTicks();
}