aboutsummaryrefslogtreecommitdiffstats
path: root/src/db/UpnpDatabasePlugin.cxx
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/db/UpnpDatabasePlugin.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/db/UpnpDatabasePlugin.cxx b/src/db/UpnpDatabasePlugin.cxx
index 5381b30a9..3c2ca72ff 100644
--- a/src/db/UpnpDatabasePlugin.cxx
+++ b/src/db/UpnpDatabasePlugin.cxx
@@ -163,9 +163,10 @@ UpnpDatabase::Open(Error &error)
if (!m_lib)
return false;
- m_superdir = UPnPDeviceDirectory::getTheDir();
- if (!m_superdir || !m_superdir->ok()) {
- error.Set(upnp_domain, "Discovery services startup failed");
+ m_superdir = new UPnPDeviceDirectory();
+ if (!m_superdir->ok()) {
+ error.Set(m_superdir->GetError());
+ delete m_superdir;
return false;
}
@@ -180,7 +181,8 @@ void
UpnpDatabase::Close()
{
delete m_root;
- // TBD decide what we do with the lib and superdir objects
+ delete m_superdir;
+ // TBD decide what we do with the lib object
}
void