diff options
author | Max Kellermann <max@duempel.org> | 2014-06-10 18:57:30 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-06-11 09:27:17 +0200 |
commit | 3364c1b8939aaf2f758a9396d0b73298042516d9 (patch) | |
tree | 046eb528b1e79d8c4bcd55e9939d58bde9981c21 /src/command | |
parent | 0801b3f495aac982bc7d009d7ae81d8e3041db0c (diff) | |
download | mpd-3364c1b8939aaf2f758a9396d0b73298042516d9.tar.gz mpd-3364c1b8939aaf2f758a9396d0b73298042516d9.tar.xz mpd-3364c1b8939aaf2f758a9396d0b73298042516d9.zip |
ClientList: use class boost::intrusive::list
Eliminate extra allocations for the std::list node instances.
Diffstat (limited to 'src/command')
-rw-r--r-- | src/command/MessageCommands.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/command/MessageCommands.cxx b/src/command/MessageCommands.cxx index fe7500aaf..02b251b9a 100644 --- a/src/command/MessageCommands.cxx +++ b/src/command/MessageCommands.cxx @@ -82,8 +82,8 @@ handle_channels(Client &client, std::set<std::string> channels; for (const auto &c : *client.partition.instance.client_list) - channels.insert(c->subscriptions.begin(), - c->subscriptions.end()); + channels.insert(c.subscriptions.begin(), + c.subscriptions.end()); for (const auto &channel : channels) client_printf(client, "channel: %s\n", channel.c_str()); @@ -122,8 +122,8 @@ handle_send_message(Client &client, bool sent = false; const ClientMessage msg(argv[1], argv[2]); - for (const auto &c : *client.partition.instance.client_list) - if (c->PushMessage(msg)) + for (auto &c : *client.partition.instance.client_list) + if (c.PushMessage(msg)) sent = true; if (sent) |