summaryrefslogtreecommitdiff
path: root/src/playlist/PlaylistQueue.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-02-07 20:27:24 +0100
committerMax Kellermann <max@duempel.org>2014-02-07 20:27:24 +0100
commit8549ccfd8c24c5666435ac4dd00ba3c7d14e0351 (patch)
tree3b7820e956b3b494dff1a21be97baa311f1ff1cb /src/playlist/PlaylistQueue.cxx
parentffd16b55a69a01b906805752acc11e26491138bc (diff)
playlist/CloseSongEnumerator: new wrapper class
Simplifies a lot of code, because we don't need to return both the SongEnumerator and the InputStream.
Diffstat (limited to 'src/playlist/PlaylistQueue.cxx')
-rw-r--r--src/playlist/PlaylistQueue.cxx9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/playlist/PlaylistQueue.cxx b/src/playlist/PlaylistQueue.cxx
index 9adea317f..85bf7ca72 100644
--- a/src/playlist/PlaylistQueue.cxx
+++ b/src/playlist/PlaylistQueue.cxx
@@ -22,9 +22,9 @@
#include "PlaylistAny.hxx"
#include "PlaylistSong.hxx"
#include "Playlist.hxx"
-#include "input/InputStream.hxx"
#include "SongEnumerator.hxx"
#include "DetachedSong.hxx"
+#include "thread/Mutex.hxx"
#include "thread/Cond.hxx"
#include "fs/Traits.hxx"
@@ -72,8 +72,7 @@ playlist_open_into_queue(const char *uri,
Mutex mutex;
Cond cond;
- InputStream *is;
- auto playlist = playlist_open_any(uri, mutex, cond, &is);
+ auto playlist = playlist_open_any(uri, mutex, cond);
if (playlist == nullptr)
return PlaylistResult::NO_SUCH_LIST;
@@ -82,9 +81,5 @@ playlist_open_into_queue(const char *uri,
start_index, end_index,
dest, pc, loader);
delete playlist;
-
- if (is != nullptr)
- is->Close();
-
return result;
}