diff options
Diffstat (limited to 'engines/titanic/support')
-rw-r--r-- | engines/titanic/support/movie.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/engines/titanic/support/movie.cpp b/engines/titanic/support/movie.cpp index 1bdcdee6da..c26e4eb3c4 100644 --- a/engines/titanic/support/movie.cpp +++ b/engines/titanic/support/movie.cpp @@ -50,15 +50,9 @@ void CMovie::init() { } void CMovie::deinit() { - // Delete each movie in turn - for (CMovieList::iterator i = _playingMovies->begin(); i != _playingMovies->end(); ) { - // We need to increment iterator before deleting movie, - // since the CMovie destructor calls removeFromPlayingMovies - CMovie *movie = *i; - ++i; - delete movie; - } - + // At this point, there shouldn't be any playing movies left, + // since their owning objects should have freed them + assert(_playingMovies->empty()); delete _playingMovies; delete _movieSurface; } |