From b999e16406ca7cdf38b1364cee48be50e2f1d756 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 24 Apr 2014 09:43:08 +0200 Subject: SongFilter: convert argv to ConstBuffer --- src/command/QueueCommands.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/command/QueueCommands.cxx') diff --git a/src/command/QueueCommands.cxx b/src/command/QueueCommands.cxx index 81e5098bb..fbcd0e8ba 100644 --- a/src/command/QueueCommands.cxx +++ b/src/command/QueueCommands.cxx @@ -31,6 +31,7 @@ #include "protocol/ArgParser.hxx" #include "protocol/Result.hxx" #include "ls.hxx" +#include "util/ConstBuffer.hxx" #include "util/UriUtil.hxx" #include "util/Error.hxx" #include "fs/AllocatedPath.hxx" @@ -231,8 +232,10 @@ static CommandResult handle_playlist_match(Client &client, int argc, char *argv[], bool fold_case) { + ConstBuffer args(argv + 1, argc - 1); + SongFilter filter; - if (!filter.Parse(argc - 1, argv + 1, fold_case)) { + if (!filter.Parse(args, fold_case)) { command_error(client, ACK_ERROR_ARG, "incorrect arguments"); return CommandResult::ERROR; } -- cgit v1.2.3