m_spanningtree fix