aboutsummaryrefslogtreecommitdiffstats
path: root/src/db/upnp/WorkQueue.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-01-14 11:02:04 +0100
committerMax Kellermann <max@duempel.org>2014-01-14 11:07:00 +0100
commitc13facdaca7ee3c9ddb9ccc3e7b75654bc268276 (patch)
tree7de1404eef19abb7728fb49132888e7311c4a967 /src/db/upnp/WorkQueue.hxx
parente25947436284ec8d54d6ba0b18111bfa37df49c0 (diff)
downloadmpd-c13facdaca7ee3c9ddb9ccc3e7b75654bc268276.tar.gz
mpd-c13facdaca7ee3c9ddb9ccc3e7b75654bc268276.tar.xz
mpd-c13facdaca7ee3c9ddb9ccc3e7b75654bc268276.zip
db/upnp/WorkQueue: pass reference to take()
Diffstat (limited to 'src/db/upnp/WorkQueue.hxx')
-rw-r--r--src/db/upnp/WorkQueue.hxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/db/upnp/WorkQueue.hxx b/src/db/upnp/WorkQueue.hxx
index 0f62ee457..d1ab7ec43 100644
--- a/src/db/upnp/WorkQueue.hxx
+++ b/src/db/upnp/WorkQueue.hxx
@@ -241,7 +241,7 @@ public:
* Sleeps if there are not enough. Signal if we go to sleep on empty
* queue: client may be waiting for our going idle.
*/
- bool take(T* tp)
+ bool take(T &tp)
{
const ScopeLock protect(m_mutex);
@@ -266,7 +266,7 @@ public:
m_workers_waiting--;
}
- *tp = m_queue.front();
+ tp = m_queue.front();
m_queue.pop();
if (m_clients_waiting > 0) {
// No reason to wake up more than one client thread