From b167ce2913690d57247b960638054a546f19d323 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 23 Jan 2014 00:03:38 +0100 Subject: [PATCH] base_uri --- src/db/UpnpDatabasePlugin.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/db/UpnpDatabasePlugin.cxx b/src/db/UpnpDatabasePlugin.cxx index c36fd4c2a..ed0794f35 100644 --- a/src/db/UpnpDatabasePlugin.cxx +++ b/src/db/UpnpDatabasePlugin.cxx @@ -567,6 +567,10 @@ UpnpDatabase::VisitServer(const ContentDirectoryService &server, return SearchSongs(server, tdirent.m_id.c_str(), selection, visit_song, error); + const char *const base_uri = selection.uri.empty() + ? server.getFriendlyName() + : selection.uri.c_str(); + if (tdirent.type == UPnPDirObject::Type::ITEM) { // Target is a song. Not too sure we ever get there actually, maybe // this is always catched by the special uri test above.