From e59d8c9378d8bdf1fcd60b26b366eae11559ee17 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 22 Jan 2014 19:20:43 +0100 Subject: db/upnp/Device: clear the "value" pointer on unknown element Avoid appending to an obsolete string object. --- src/db/upnp/Device.cxx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/db/upnp/Device.cxx b/src/db/upnp/Device.cxx index dd1a8f43c..2dab1b4c5 100644 --- a/src/db/upnp/Device.cxx +++ b/src/db/upnp/Device.cxx @@ -45,6 +45,8 @@ public: protected: virtual void StartElement(const XML_Char *name, const XML_Char **) { + value = nullptr; + switch (name[0]) { case 'c': if (strcmp(name, "controlURL") == 0) -- cgit v1.2.3