From fc8dc9531193e872dd65914f8ffa1491bc5cf9ff Mon Sep 17 00:00:00 2001 From: chriszero Date: Fri, 22 May 2015 19:46:31 +0200 Subject: Fixes complie error --- PlexHTTPRequestHandler.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/PlexHTTPRequestHandler.cpp b/PlexHTTPRequestHandler.cpp index 5339258..4fade01 100644 --- a/PlexHTTPRequestHandler.cpp +++ b/PlexHTTPRequestHandler.cpp @@ -226,16 +226,16 @@ void PlayerRequestHandler::handleRequest(Poco::Net::HTTPServerRequest& request, std::string fullUrl = protocol + "://" + address + ":" + port + key; // Metainfo std::cout << fullUrl << std::endl; - MediaContainer Cont = Plexservice::GetMediaContainer(fullUrl); + auto Cont = Plexservice::GetMediaContainer(fullUrl); // Check for video - if(Cont.m_vVideos.size() > 0) { + if(Cont && Cont->m_vVideos.size() > 0) { // MUSS im Maintread des Plugins/VDR gestartet werden if(query.find("offset") != query.end()) { - Cont.m_vVideos[0].m_iMyPlayOffset = atoi(query["offset"].c_str()) / 1000; + Cont->m_vVideos[0].m_iMyPlayOffset = atoi(query["offset"].c_str()) / 1000; } - ActionManager::GetInstance().AddAction(Cont.m_vVideos[0]); + ActionManager::GetInstance().AddAction(Cont->m_vVideos[0]); } } else if(request.getURI().find("/playback/play") != std::string::npos) { cRemote::Put(kPlay); -- cgit v1.2.3