Commit b0a2d7a4 authored by charras's avatar charras

fixed seg fault in DRC just after a .ses import

parent 64f501ba
......@@ -187,6 +187,10 @@ int DRC::Drc( ZONE_CONTAINER * aArea, int CornerIndex )
void DRC::RunTests()
{
// Ensure ratsnest is up to date:
if( (m_pcb->m_Status_Pcb & LISTE_CHEVELU_OK) == 0 )
m_mainWindow->Compile_Ratsnest( NULL, true );
// someone should have cleared the two lists before calling this.
// test pad to pad clearances, nothing to do with tracks, vias or zones.
......@@ -197,7 +201,7 @@ void DRC::RunTests()
testTracks();
// Before testing segments and unconnected, refill all zones:
// this is a good caution, and mandatory if using filling zones by solid polygons
// this is a good caution, because filled areas can be outdated.
m_mainWindow->Fill_All_Zones( false );
// test zone clearances to other zones, pads, tracks, and vias
......
......@@ -256,7 +256,7 @@ librairi.o: librairi.cpp
edgemod.o: edgemod.cpp
muonde.o: muonde.cpp drag.h gen_self.h
muonde.o: muonde.cpp drag.h
autorout.o: autorout.cpp cell.h autorout.h
......
......@@ -104,7 +104,7 @@ void WinEDA_BasePcbFrame::Compile_Ratsnest( wxDC* DC, bool display_status_pcb )
* Must be called after a board change (changes for
* pads, footprints or a read netlist ).
*
* if display_status_pcb != 0 : Display the computation results
* if display_status_pcb == true : Display the computation results
*/
{
wxString msg;
......
......@@ -115,6 +115,15 @@ void WinEDA_PcbFrame::ImportSpecctraSession( wxCommandEvent& event )
GetScreen()->SetModify();
GetBoard()->m_Status_Pcb = 0;
/* At this point we should call Compile_Ratsnest()
* but this could be time consumming.
* So if incorrect number of Connecred and No connected pads is accepted
* until Compile_Ratsnest() is called (when track tool selected for instance)
* leave the next line commented
* Otherwise uncomment this line
*/
//Compile_Ratsnest( NULL, true );
Affiche_Message( wxString( _("Session file imported and merged OK.")) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment