Merge remote-tracking branches 'neheb/uniq', 'neheb/bool', 'neheb/loop', 'neheb/bool2', 'neheb/perf', 'neheb/void' and 'neheb/value'

This commit is contained in:
Max Kellermann
2020-02-02 16:22:19 +01:00
26 changed files with 49 additions and 51 deletions

View File

@@ -23,14 +23,15 @@
#include "song/Filter.hxx"
#include <algorithm>
#include <utility>
#include <assert.h>
#include <stdlib.h>
#include <string.h>
DatabaseVisitorHelper::DatabaseVisitorHelper(const DatabaseSelection &_selection,
DatabaseVisitorHelper::DatabaseVisitorHelper(DatabaseSelection _selection,
VisitSong &visit_song) noexcept
:selection(_selection)
:selection(std::move(_selection))
{
// TODO: apply URI and SongFilter
assert(selection.uri.empty());

View File

@@ -60,7 +60,7 @@ public:
* @param visit_song the callback function passed to
* Database::Visit(); may be replaced by this class
*/
DatabaseVisitorHelper(const DatabaseSelection &selection,
DatabaseVisitorHelper(DatabaseSelection selection,
VisitSong &visit_song) noexcept;
~DatabaseVisitorHelper() noexcept;

View File

@@ -863,10 +863,7 @@ IsFilterSupported(const ISongFilter &f) noexcept
return true;
const auto tag = Convert(t->GetTagType());
if (tag == MPD_TAG_COUNT)
return false;
return true;
return tag != MPD_TAG_COUNT;
} else if (auto u = dynamic_cast<const UriSongFilter *>(&f)) {
if (u->IsNegated())
// TODO implement

View File

@@ -330,7 +330,7 @@ mpd_inotify_init(EventLoop &loop, Storage &storage, UpdateService &update,
}
void
mpd_inotify_finish(void) noexcept
mpd_inotify_finish() noexcept
{
if (inotify_source == nullptr)
return;