diff --git a/src/Fl_Group.cxx b/src/Fl_Group.cxx index aefead997..2ec83d493 100644 --- a/src/Fl_Group.cxx +++ b/src/Fl_Group.cxx @@ -452,6 +452,8 @@ void Fl_Group::clear() { widgets' destructors would be called twice! */ Fl_Group::~Fl_Group() { + if (current_ == this) + end(); clear(); }