Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion src/Vizkit3DWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,16 @@ Vizkit3DWidget::Vizkit3DWidget( QWidget* parent,int width,int height,const QStri
_timer.start(10);
}

Vizkit3DWidget::~Vizkit3DWidget() {}
Vizkit3DWidget::~Vizkit3DWidget()
{
delete env_plugin;
env_plugin = NULL;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you're using C++ >= 11, use nullptr instead of NULL.

while (!plugins.empty()) {
auto plugin = plugins.begin()->first;
deregisterDataHandler(plugin);
delete plugin;
}
}

//qt ruby is crashing if we use none pointer here
QStringList* Vizkit3DWidget::getVisualizationFramesRuby() const
Expand Down