aboutsummaryrefslogtreecommitdiffstats
path: root/src/config/Data.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2015-01-21 22:56:20 +0100
committerMax Kellermann <max@duempel.org>2015-01-21 23:30:00 +0100
commita33db8fe6f4d8a0496a723914cc33c2f76000c4e (patch)
treef34e3e891f76dc41eb54588b4a34562fe4b19b72 /src/config/Data.cxx
parent1c3f5517fabc264d7b37935bd37197cdd68250ba (diff)
downloadmpd-a33db8fe6f4d8a0496a723914cc33c2f76000c4e.tar.gz
mpd-a33db8fe6f4d8a0496a723914cc33c2f76000c4e.tar.xz
mpd-a33db8fe6f4d8a0496a723914cc33c2f76000c4e.zip
config/Data: assign nullptr during iteration
Diffstat (limited to 'src/config/Data.cxx')
-rw-r--r--src/config/Data.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/config/Data.cxx b/src/config/Data.cxx
index ae36b7f21..4aae9f7dc 100644
--- a/src/config/Data.cxx
+++ b/src/config/Data.cxx
@@ -24,7 +24,8 @@
void
ConfigData::Clear()
{
- for (auto i : params)
+ for (auto &i : params) {
delete i;
- params.fill(nullptr);
+ i = nullptr;
+ }
}