#574·Havoc

fix client crash when removing agents from the ui

Author: skimask1690Created Dec 23, 2025Updated Dec 25, 2025
Labelsclientside/teamserver

Contact Details

No response

What happened?

cpp
// Erase NodeList after removeChild (client/src/UserInterface/Widgets/SessionGraph.cc)

void GraphWidget::GraphNodeRemove( SessionItem Session )
{
    for ( int i = 0; i < NodeList.size(); i++ )
    {
        if ( Session.Name.compare( NodeList[ i ]->Name ) == 0 )
        {
            GraphScene->removeItem( NodeList[ i ]->Node->NodeEdge );
            GraphScene->removeItem( NodeList[ i ]->Node );

            MainNode->Node->removeChild( NodeList[ i ]->Node );

            /* delete NodeList[ i ]->Node->NodeEdge;
            delete NodeList[ i ]->Node;
            delete NodeList[ i ]; */

            NodeList.erase( NodeList.begin() + i ); // fix is here

            return;
        }
    }
}

Did You Do a Pull First?

Latest (You performed a pull first)

Did You Try With the Dev Branch?

Yes (You tried using the dev branch but the problem persist)

Relevant log output

bash
/usr/include/c++/15/bits/stl_vector.h:1263: constexpr std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = GraphWidget::Member*; _Alloc = std::allocator<GraphWidget::Member*>; reference = GraphWidget::Member*&; size_type = long unsigned int]: Assertion '__n < this->size()' failed.
Error: signal: aborted

Did You Read Over Your Issue First?

  • I declare I made an effort and provided the necessary information for replication of the issue.