X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fpluginclient.C;fp=cinelerra-5.1%2Fcinelerra%2Fpluginclient.C;h=f1fe25b9f9e90581756f5668bc12ca18c104368e;hb=ae44cc4a24c9e04ee5e3b38baf6ce529832cfb39;hp=0a690b2e673868d3e65700da5c323022f90abc91;hpb=2ce5f3585284c78107b6eab879ee4e94686ff41a;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/cinelerra/pluginclient.C b/cinelerra-5.1/cinelerra/pluginclient.C index 0a690b2e..f1fe25b9 100644 --- a/cinelerra-5.1/cinelerra/pluginclient.C +++ b/cinelerra-5.1/cinelerra/pluginclient.C @@ -201,8 +201,11 @@ PluginClient::PluginClient(PluginServer *server) PluginClient::~PluginClient() { -// Delete the GUI thread. The GUI must be hidden with hide_gui first. - delete thread; + if( thread ) { + hide_gui(); + thread->join(); + delete thread; + } // Virtual functions don't work here. if(defaults) delete defaults; @@ -245,8 +248,6 @@ void PluginClient::hide_gui() thread->window->set_done(0); //printf("PluginClient::hide_gui %d thread->window=%p\n", __LINE__, thread->window); thread->window->unlock_window(); -//printf("PluginClient::delete_thread %d\n", __LINE__); - thread->join(); } }