[Alsaplayer-devel]Playlist and CorePlayer

Evgeny Chukreev codedj@echo.ru
Tue, 23 Apr 2002 20:35:01 +0700


What good is to delete CorePlayer instance inside Playlist destructor?
What if CorePlayer is in use anywhere else? I just want to delete Playlist without
deletion of associated CorePlayer..

Playlist::~Playlist() {
	active = false;
	pthread_join(playlist_thread, NULL);
	interfaces.clear();	// Unregister all interfaces
	// FIXME - need to do something to kill off an insert thread, if one is
	// running - otherwise it might have its playlist torn from underneath it
	// We currently just wait for the thread to finish
	if (adder) {
			//printf("Waiting for insert thread to finish\n");
	    pthread_join(adder, NULL);
	if (player1)
		delete player1;
	if (player2)
		delete player2;


... Evgeny ... [Nothing]