debug cosmetics
authorMirakels <mirakels@openpli.org>
Sun, 29 Mar 2015 10:30:57 +0000 (12:30 +0200)
committerMirakels <mirakels@openpli.org>
Sun, 29 Mar 2015 10:31:21 +0000 (12:31 +0200)
lib/dvb/db.cpp
lib/dvb/decoder.cpp
lib/dvb/dvb.cpp
lib/dvb/volume.cpp
lib/service/servicedvb.cpp

index a122ec3..0a531ec 100644 (file)
@@ -56,7 +56,7 @@ RESULT eBouquet::removeService(const eServiceReference &ref, bool renameBouquet)
                                filename = eEnv::resolve("${sysconfdir}/enigma2/" + filename);
                                std::string newfilename(filename);
                                newfilename.append(".del");
-                               eDebug("Rename bouquet file %s to %s", filename.c_str(), newfilename.c_str());
+                               eDebug("[eBouquet] Rename bouquet file %s to %s", filename.c_str(), newfilename.c_str());
                                rename(filename.c_str(), newfilename.c_str());
                        }
                }
@@ -123,7 +123,7 @@ RESULT eBouquet::flushChanges()
        rename((filename + ".writing").c_str(), filename.c_str());
        return 0;
 err:
-       eDebug("couldn't write file %s", m_filename.c_str());
+       eDebug("[eBouquet] couldn't write file %s", m_filename.c_str());
        return -1;
 }
 
@@ -201,7 +201,7 @@ int eDVBService::isPlayable(const eServiceReference &ref, const eServiceReferenc
        bool remote_fallback_enabled = eConfigManager::getConfigBoolValue("config.usage.remote_fallback_enabled", false);
 
        if (eDVBResourceManager::getInstance(res_mgr))
-               eDebug("isPlayble... no res manager!!");
+               eDebug("[eDVBService] isPlayble... no res manager!!");
        else
        {
                eDVBChannelID chid, chid_ignore;
@@ -369,7 +369,7 @@ void eDVBDB::parseServiceData(ePtr<eDVBService> s, std::string str)
                        v=str.substr(2, c-2);
                        str=str.substr(c+1);
                }
-//             eDebug("%c ... %s", p, v.c_str());
+//             eDebug("[eDVBDB] %c ... %s", p, v.c_str());
                if (p == 'p')
                        s->m_provider_name=v;
                else if (p == 'f')
@@ -517,10 +517,10 @@ static eServiceReferenceDVB parseServiceRefData(const char *line)
 
 void eDVBDB::loadServicelist(const char *file)
 {
-       eDebug("---- opening lame channel db");
+       eDebug("[eDVBDB] ---- opening lame channel db");
        CFile f(file, "rt");
        if (!f) {
-               eDebug("can't open %s: %m", file);
+               eDebug("[eDVBDB] can't open %s: %m", file);
                return;
        }
 
@@ -528,14 +528,14 @@ void eDVBDB::loadServicelist(const char *file)
        int version;
        if ((!fgets(line, sizeof(line), f)) || sscanf(line, "eDVB services /%d/", &version) != 1)
        {
-               eDebug("not a valid servicefile");
+               eDebug("[eDVBDB] not a valid servicefile");
                return;
        }
-       eDebug("reading services (version %d)", version);
+       eDebug("[eDVBDB] reading services (version %d)", version);
 
        if ((!fgets(line, sizeof(line), f)) || strcmp(line, "transponders\n"))
        {
-               eDebug("services invalid, no transponders");
+               eDebug("[eDVBDB] services invalid, no transponders");
                return;
        }
        // clear all transponders
@@ -562,7 +562,7 @@ void eDVBDB::loadServicelist(const char *file)
 
        if ((!fgets(line, sizeof(line), f)) || strcmp(line, "services\n"))
        {
-               eDebug("services invalid, no services");
+               eDebug("[eDVBDB] services invalid, no services");
                return;
        }
        // clear all services
@@ -598,18 +598,18 @@ void eDVBDB::loadServicelist(const char *file)
                scount++;
        }
 
-       eDebug("loaded %d channels/transponders and %d services", tcount, scount);
+       eDebug("[eDVBDB] loaded %d channels/transponders and %d services", tcount, scount);
 }
 
 void eDVBDB::saveServicelist(const char *file)
 {
-       eDebug("---- saving lame channel db");
+       eDebug("[eDVBDB] ---- saving lame channel db");
        std::string filename = file;
        {
        CFile f((filename + ".writing").c_str(), "w");
        int channels=0, services=0;
        if (!f)
-               eFatal("couldn't save lame channel db!");
+               eFatal("[eDVBDB] couldn't save lame channel db!");
        fprintf(f, "eDVB services /4/\n");
        fprintf(f, "transponders\n");
        for (std::map<eDVBChannelID, channel>::const_iterator i(m_channels.begin());
@@ -725,7 +725,7 @@ void eDVBDB::saveServicelist(const char *file)
                services++;
        }
        fprintf(f, "end\nHave a lot of bugs!\n");
-       eDebug("saved %d channels and %d services!", channels, services);
+       eDebug("[eDVBDB] saved %d channels and %d services!", channels, services);
        f.sync();
        }
        rename((filename + ".writing").c_str(), filename.c_str());
@@ -750,7 +750,7 @@ void eDVBDB::loadBouquet(const char *path)
                DIR *dir = opendir(p.c_str());
                if (!dir)
                {
-                       eDebug("Cannot open directory where the userbouquets should be expected..");
+                       eDebug("[eDVBDB] Cannot open directory where the userbouquets should be expected..");
                        return;
                }
                dirent *entry;
@@ -766,7 +766,7 @@ void eDVBDB::loadBouquet(const char *path)
        std::string bouquet_name = path;
        if (!bouquet_name.length())
        {
-               eDebug("Bouquet load failed.. no path given..");
+               eDebug("[eDVBDB] Bouquet load failed.. no path given..");
                return;
        }
        size_t pos = bouquet_name.rfind('/');
@@ -774,7 +774,7 @@ void eDVBDB::loadBouquet(const char *path)
                bouquet_name.erase(0, pos+1);
        if (bouquet_name.empty())
        {
-               eDebug("Bouquet load failed.. no filename given..");
+               eDebug("[eDVBDB] Bouquet load failed.. no filename given..");
                return;
        }
        eBouquet &bouquet = m_bouquets[bouquet_name];
@@ -802,12 +802,12 @@ void eDVBDB::loadBouquet(const char *path)
 
        if(!found)
        {
-               eDebug("can't open %s: %m", (enigma_conf + ".../" + path).c_str());
+               eDebug("[eDVBDB] can't open %s: %m", (enigma_conf + ".../" + path).c_str());
                if (!strcmp(path, "bouquets.tv"))
                {
                        file_path = enigma_conf + path;
 
-                       eDebug("recreate bouquets.tv");
+                       eDebug("[eDVBDB] recreate bouquets.tv");
                        bouquet.m_bouquet_name="Bouquets (TV)";
                        bouquet.flushChanges();
                }
@@ -817,7 +817,7 @@ void eDVBDB::loadBouquet(const char *path)
                        {
                                file_path = enigma_conf + path;
 
-                               eDebug("recreate bouquets.radio");
+                               eDebug("[eDVBDB] recreate bouquets.radio");
                                bouquet.m_bouquet_name="Bouquets (Radio)";
                                bouquet.flushChanges();
                        }
@@ -826,7 +826,7 @@ void eDVBDB::loadBouquet(const char *path)
                }
        }
 
-       eDebug("loading bouquet... %s", file_path.c_str());
+       eDebug("[eDVBDB] loading bouquet... %s", file_path.c_str());
        CFile fp(file_path, "rt");
 
        if (fp)
@@ -856,7 +856,7 @@ void eDVBDB::loadBouquet(const char *path)
                                                path.erase(0, pos+1);
                                        if (path.empty())
                                        {
-                                               eDebug("Bouquet load failed.. no filename given..");
+                                               eDebug("[eDVBDB] Bouquet load failed.. no filename given..");
                                                continue;
                                        }
                                        pos = path.find("FROM BOUQUET ");
@@ -865,7 +865,7 @@ void eDVBDB::loadBouquet(const char *path)
                                                char endchr = path[pos+13];
                                                if (endchr != '"')
                                                {
-                                                       eDebug("ignore invalid bouquet '%s' (only \" are allowed)",
+                                                       eDebug("[eDVBDB] ignore invalid bouquet '%s' (only \" are allowed)",
                                                                tmp.toString().c_str());
                                                        continue;
                                                }
@@ -911,7 +911,7 @@ void eDVBDB::loadBouquet(const char *path)
                {
                        if (m_load_unlinked_userbouquets)
                        {
-                               eDebug("Adding additional userbouquet %s", userbouquetsfiles[i].c_str());
+                               eDebug("[eDVBDB] Adding additional userbouquet %s", userbouquetsfiles[i].c_str());
                                char buf[256];
                                if (!strcmp(path, "bouquets.tv"))
                                        snprintf(buf, sizeof(buf), "1:7:1:0:0:0:0:0:0:0:FROM BOUQUET \"%s\" ORDER BY bouquet", userbouquetsfiles[i].c_str());
@@ -930,13 +930,13 @@ void eDVBDB::loadBouquet(const char *path)
                                std::string filename = eEnv::resolve("${sysconfdir}/enigma2/" + userbouquetsfiles[i]);
                                std::string newfilename(filename);
                                newfilename.append(".del");
-                               eDebug("Rename unlinked bouquet file %s to %s", filename.c_str(), newfilename.c_str());
+                               eDebug("[eDVBDB] Rename unlinked bouquet file %s to %s", filename.c_str(), newfilename.c_str());
                                rename(filename.c_str(), newfilename.c_str());
                        }
                }
                bouquet.flushChanges();
        }
-       eDebug("%d entries in Bouquet %s", entries, bouquet_name.c_str());
+       eDebug("[eDVBDB] %d entries in Bouquet %s", entries, bouquet_name.c_str());
 }
 
 void eDVBDB::reloadBouquets()
@@ -980,7 +980,7 @@ void eDVBDB::reloadBouquets()
 
 void eDVBDB::renumberBouquet()
 {
-       eDebug("Renumbering...");
+       eDebug("[eDVBDB] Renumbering...");
        renumberBouquet( m_bouquets["bouquets.tv"] );
        renumberBouquet( m_bouquets["bouquets.radio"] );
 }
@@ -1044,21 +1044,21 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
        if (!PyDict_Check(tp_dict)) {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 2 is not a python dict");
+                       eDebug("[eDVBDB] readSatellites arg 2 is not a python dict");
                return NULL;
        }
        else if (!PyDict_Check(sat_dict))
        {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 1 is not a python dict");
+                       eDebug("[eDVBDB] readSatellites arg 1 is not a python dict");
                return NULL;
        }
        else if (!PyList_Check(sat_list))
        {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 0 is not a python list");
+                       eDebug("[eDVBDB] readSatellites arg 0 is not a python list");
                return NULL;
        }
        XMLTree tree;
@@ -1072,7 +1072,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
        Element *root = tree.getRoot();
        if (!root)
        {
-               eDebug("couldn't open /etc/tuxbox/satellites.xml!!");
+               eDebug("[eDVBDB] couldn't open /etc/tuxbox/satellites.xml!!");
                Py_INCREF(Py_False);
                return Py_False;
        }
@@ -1084,7 +1084,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
        const ElementList &root_elements = root->getElementList();
        for (ElementConstIterator it(root_elements.begin()); it != root_elements.end(); ++it)
        {
-//             eDebug("element: %s", (*it)->name().c_str());
+//             eDebug("[eDVBDB] element: %s", (*it)->name().c_str());
                const Element *el = *it;
                const ElementList &sat_elements = el->getElementList();
                const AttributeList &sat_attributes = el->getAttributeList();
@@ -1093,7 +1093,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
                ePyObject sat_flags;
                for (AttributeConstIterator it(sat_attributes.begin()); it != sat_attributes.end(); ++it)
                {
-//                     eDebug("\tattr: %s", at->name().c_str());
+//                     eDebug("[eDVBDB] \tattr: %s", at->name().c_str());
                        at = *it;
                        name = at->name();
                        if (name == "name")
@@ -1130,7 +1130,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
                        PyDict_SetItem(tp_dict, sat_pos, tplist);
                        for (ElementConstIterator it(sat_elements.begin()); it != sat_elements.end(); ++it)
                        {
-                               //eDebug("\telement: %s", (*it)->name().c_str());
+                               //eDebug("[eDVBDB] \telement: %s", (*it)->name().c_str());
                                const AttributeList &tp_attributes = (*it)->getAttributeList();
                                AttributeConstIterator end = tp_attributes.end();
                                modulation = eDVBFrontendParametersSatellite::Modulation_QPSK;
@@ -1148,7 +1148,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
                                for (AttributeConstIterator it(tp_attributes.begin()); it != end; ++it)
                                {
                                        at = *it;
-                                       //eDebug("\t\tattr: %s", at->name().c_str());
+                                       //eDebug("[eDVBDB] \t\tattr: %s", at->name().c_str());
                                        name = at->name();
                                        if (name == "modulation") dest = &modulation;
                                        else if (name == "system") dest = &system;
@@ -1164,7 +1164,7 @@ PyObject *eDVBDB::readSatellites(ePyObject sat_list, ePyObject sat_dict, ePyObje
                                        else continue;
                                        if (dest)
                                        {
-                                               //eDebug("\t\t\tvalue: %s", at->value().c_str());
+                                               //eDebug("[eDVBDB] \t\t\tvalue: %s", at->value().c_str());
                                                tmp = strtol(at->value().c_str(), &end_ptr, 10);
                                                if (!*end_ptr)
                                                        *dest = tmp;
@@ -1210,14 +1210,14 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
        if (!PyDict_Check(tp_dict)) {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 1 is not a python dict");
+                       eDebug("[eDVBDB] readCables arg 1 is not a python dict");
                return NULL;
        }
        else if (!PyList_Check(cab_list))
        {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 0 is not a python list");
+                       eDebug("[eDVBDB] readCables arg 0 is not a python list");
                return NULL;
        }
        XMLTree tree;
@@ -1226,7 +1226,7 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
        Element *root = tree.getRoot();
        if (!root)
        {
-               eDebug("couldn't open /etc/tuxbox/cables.xml!!");
+               eDebug("[eDVBDB] couldn't open /etc/tuxbox/cables.xml!!");
                Py_INCREF(Py_False);
                return Py_False;
        }
@@ -1238,7 +1238,7 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
        const ElementList &root_elements = root->getElementList();
        for (ElementConstIterator it(root_elements.begin()); it != root_elements.end(); ++it)
        {
-//             eDebug("element: %s", el->name().c_str());
+//             eDebug("[eDVBDB] element: %s", el->name().c_str());
                const Element *el = *it;
                const ElementList &cab_elements = el->getElementList();
                const AttributeList &cab_attributes = el->getAttributeList();
@@ -1246,7 +1246,7 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
                ePyObject cab_flags;
                for (AttributeConstIterator it(cab_attributes.begin()); it != cab_attributes.end(); ++it)
                {
-//                     eDebug("\tattr: %s", at->name().c_str());
+//                     eDebug("[eDVBDB]\tattr: %s", at->name().c_str());
                        at = *it;
                        name = at->name();
                        if (name == "name")
@@ -1271,7 +1271,7 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
                        PyDict_SetItem(tp_dict, cab_name, tplist);
                        for (ElementConstIterator it(cab_elements.begin()); it != cab_elements.end(); ++it)
                        {
-//                             eDebug("\telement: %s", (*it)->name().c_str());
+//                             eDebug("[eDVBDB]\telement: %s", (*it)->name().c_str());
                                const AttributeList &tp_attributes = (*it)->getAttributeList();
                                AttributeConstIterator end = tp_attributes.end();
                                modulation = eDVBFrontendParametersCable::Modulation_QAM64;
@@ -1282,7 +1282,7 @@ PyObject *eDVBDB::readCables(ePyObject cab_list, ePyObject tp_dict)
                                sr = 0;
                                for (AttributeConstIterator it(tp_attributes.begin()); it != end; ++it)
                                {
-//                                     eDebug("\t\tattr: %s", at->name().c_str());
+//                                     eDebug("[eDVBDB]\t\tattr: %s", at->name().c_str());
                                        at = *it;
                                        dest = 0;
                                        name = at->name();
@@ -1330,14 +1330,14 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
        if (!PyDict_Check(tp_dict)) {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 1 is not a python dict");
+                       eDebug("[eDVBDB] readTerrestrials arg 1 is not a python dict");
                return NULL;
        }
        else if (!PyList_Check(ter_list))
        {
                PyErr_SetString(PyExc_StandardError,
                        "type error");
-                       eDebug("arg 0 is not a python list");
+                       eDebug("[eDVBDB] readTerrestrials arg 0 is not a python list");
                return NULL;
        }
        XMLTree tree;
@@ -1346,7 +1346,7 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
        Element *root = tree.getRoot();
        if (!root)
        {
-               eDebug("couldn't open /etc/tuxbox/terrestrial.xml!!");
+               eDebug("[eDVBDB] couldn't open /etc/tuxbox/terrestrial.xml!!");
                Py_INCREF(Py_False);
                return Py_False;
        }
@@ -1358,7 +1358,7 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
        const ElementList &root_elements = root->getElementList();
        for (ElementConstIterator it(root_elements.begin()); it != root_elements.end(); ++it)
        {
-//             eDebug("element: %s", el->name().c_str());
+//             eDebug("[eDVBDB] element: %s", el->name().c_str());
                const Element *el = *it;
                const ElementList &ter_elements = el->getElementList();
                const AttributeList &ter_attributes = el->getAttributeList();
@@ -1366,7 +1366,7 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
                ePyObject ter_flags;
                for (AttributeConstIterator it(ter_attributes.begin()); it != ter_attributes.end(); ++it)
                {
-//                     eDebug("\tattr: %s", at->name().c_str());
+//                     eDebug("[eDVBDB]\tattr: %s", at->name().c_str());
                        at = *it;
                        name = at->name();
                        if (name == "name")
@@ -1391,7 +1391,7 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
                        PyDict_SetItem(tp_dict, ter_name, tplist);
                        for (ElementConstIterator it(ter_elements.begin()); it != ter_elements.end(); ++it)
                        {
-//                             eDebug("\telement: %s", (*it)->name().c_str());
+//                             eDebug("[eDVBDB]\telement: %s", (*it)->name().c_str());
                                const AttributeList &tp_attributes = (*it)->getAttributeList();
                                AttributeConstIterator end = tp_attributes.end();
                                freq = 0;
@@ -1407,7 +1407,7 @@ PyObject *eDVBDB::readTerrestrials(ePyObject ter_list, ePyObject tp_dict)
                                plpid = 0;
                                for (AttributeConstIterator it(tp_attributes.begin()); it != end; ++it)
                                {
-//                                     eDebug("\t\tattr: %s", at->name().c_str());
+//                                     eDebug("[eDVBDB]\t\tattr: %s", at->name().c_str());
                                        at = *it;
                                        dest = 0;
                                        name = at->name();
@@ -1536,7 +1536,7 @@ RESULT eDVBDB::removeServices(eDVBChannelID chid, unsigned int orbpos)
                        remove=false;
                if ( remove )
                {
-                       eDebug("remove %08x %04x %04x",
+                       eDebug("[eDVBDB] remove %08x %04x %04x",
                                ch.dvbnamespace.get(),
                                ch.original_network_id.get(),
                                ch.transport_stream_id.get());
@@ -1750,7 +1750,7 @@ RESULT eDVBDB::getBouquet(const eServiceReference &ref, eBouquet* &bouquet)
        std::string str = ref.path;
        if (str.empty())
        {
-               eDebug("getBouquet failed.. no path given!");
+               eDebug("[eDVBDB] getBouquet failed.. no path given!");
                return -1;
        }
        size_t pos = str.find("FROM BOUQUET \"");
@@ -1765,7 +1765,7 @@ RESULT eDVBDB::getBouquet(const eServiceReference &ref, eBouquet* &bouquet)
        }
        if (str.empty())
        {
-               eDebug("getBouquet failed.. couldn't parse bouquet name");
+               eDebug("[eDVBDB] getBouquet failed.. couldn't parse bouquet name");
                return -1;
        }
        std::map<std::string, eBouquet>::iterator i =
@@ -1790,7 +1790,7 @@ RESULT eDVBDB::startQuery(ePtr<iDVBChannelListQuery> &query, eDVBChannelQuery *q
                else if ( source.path.find("PROVIDERS") != std::string::npos )
                        query = new eDVBDBProvidersQuery(this, source, q);
                else
-                       eFatal("invalid query %s", source.toString().c_str());
+                       eFatal("[eDVBDB] invalid query %s", source.toString().c_str());
        }
        else
                query = new eDVBDBQuery(this, source, q);
@@ -2007,14 +2007,14 @@ eDVBDBSatellitesQuery::eDVBDBSatellitesQuery(eDVBDB *db, const eServiceReference
                                unsigned int pos=ref.path.find("FROM");
                                ref.path.erase(pos);
                                ref.path+="ORDER BY name";
-//                             eDebug("ref.path now %s", ref.path.c_str());
+//                             eDebug("[eDVBDB] ref.path now %s", ref.path.c_str());
                                m_list.push_back(ref);
 
                                ref.path=buf+source.path;
                                pos=ref.path.find("FROM");
                                ref.path.erase(pos+5);
                                ref.path+="PROVIDERS ORDER BY name";
-//                             eDebug("ref.path now %s", ref.path.c_str());
+//                             eDebug("[eDVBDB] ref.path now %s", ref.path.c_str());
                                m_list.push_back(ref);
 
                                snprintf(buf, sizeof(buf), "(satellitePosition == %d) && (flags == %d) && ", dvbnamespace>>16, eDVBService::dxNewFound);
@@ -2022,7 +2022,7 @@ eDVBDBSatellitesQuery::eDVBDBSatellitesQuery(eDVBDB *db, const eServiceReference
                                pos=ref.path.find("FROM");
                                ref.path.erase(pos);
                                ref.path+="ORDER BY name";
-//                             eDebug("ref.path now %s", ref.path.c_str());
+//                             eDebug("[eDVBDB] ref.path now %s", ref.path.c_str());
                                m_list.push_back(ref);
                        }
                }
@@ -2055,7 +2055,7 @@ eDVBDBProvidersQuery::eDVBDBProvidersQuery(eDVBDB *db, const eServiceReference &
                                ref.flags=eServiceReference::flagDirectory;
                                ref.path.erase(pos);
                                ref.path+="ORDER BY name";
-//                             eDebug("ref.path now %s", ref.path.c_str());
+//                             eDebug("[eDVBDB] ref.path now %s", ref.path.c_str());
                                m_list.push_back(ref);
                        }
                }
@@ -2104,7 +2104,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
 
                if (end_of_exp == end)
                {
-                       eDebug("expression parse: end of expression while searching for closing brace");
+                       eDebug("[parseExpression] end of expression while searching for closing brace");
                        return -1;
                }
 
@@ -2118,7 +2118,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
                        /* we had only one sub expression */
                if (end_of_exp == end)
                {
-//                     eDebug("only one sub expression");
+//                     eDebug("[parseExpression] only one sub expression");
                        return 0;
                }
 
@@ -2137,7 +2137,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
                        res->m_type = eDVBChannelQuery::tAND;
                else
                {
-                       eDebug("found operator %s, but only && and || are allowed!", end_of_exp->c_str());
+                       eDebug("[parseExpression] found operator %s, but only && and || are allowed!", end_of_exp->c_str());
                        res = 0;
                        return 1;
                }
@@ -2168,7 +2168,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
                        val = *begin;
                        break;
                case 3:
-                       eDebug("malformed query: got '%s', but expected only <type> <op> <val>", begin->c_str());
+                       eDebug("[parseExpression] malformed query: got '%s', but expected only <type> <op> <val>", begin->c_str());
                        return 1;
                }
                ++begin;
@@ -2177,7 +2177,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
 
        if (cnt != 3)
        {
-               eDebug("malformed query: missing stuff");
+               eDebug("[parseExpression] malformed query: missing stuff");
                res = 0;
                return 1;
        }
@@ -2186,7 +2186,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
 
        if (res->m_type == -1)
        {
-               eDebug("malformed query: invalid type %s", type.c_str());
+               eDebug("[parseExpression] malformed query: invalid type %s", type.c_str());
                res = 0;
                return 1;
        }
@@ -2197,7 +2197,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
                res->m_inverse = 1;
        else
        {
-               eDebug("invalid operator %s", op.c_str());
+               eDebug("[parseExpression] invalid operator %s", op.c_str());
                res = 0;
                return 1;
        }
@@ -2210,7 +2210,7 @@ RESULT parseExpression(ePtr<eDVBChannelQuery> &res, std::list<std::string>::cons
                if (sscanf(val.c_str(), "%08x%04x%04x", &ns, &tsid, &onid) == 3)
                        res->m_channelid = eDVBChannelID(eDVBNamespace(ns), eTransportStreamID(tsid), eOriginalNetworkID(onid));
                else
-                       eDebug("couldn't parse channelid !! format should be hex NNNNNNNNTTTTOOOO (namespace, tsid, onid)");
+                       eDebug("[parseExpression] couldn't parse channelid !! format should be hex NNNNNNNNTTTTOOOO (namespace, tsid, onid)");
        }
        else
                res->m_int = atoi(val.c_str());
@@ -2225,7 +2225,7 @@ RESULT eDVBChannelQuery::compile(ePtr<eDVBChannelQuery> &res, std::string query)
        std::string current_token;
        std::string bouquet_name;
 
-//     eDebug("splitting %s....", query.c_str());
+//     eDebug("[eDVBChannelQuery] splitting %s....", query.c_str());
        unsigned int i = 0;
        const char *splitchars="()";
        int quotemode = 0, lastsplit = 0, lastalnum = 0;
@@ -2298,7 +2298,7 @@ RESULT eDVBChannelQuery::compile(ePtr<eDVBChannelQuery> &res, std::string query)
                                tokens.erase(it++);
                        else
                        {
-                               eDebug("FROM unknown %s", (*it).c_str());
+                               eDebug("[eDVBChannelQuery] FROM unknown %s", (*it).c_str());
                                tokens.erase(it++);
                        }
                }
@@ -2308,12 +2308,12 @@ RESULT eDVBChannelQuery::compile(ePtr<eDVBChannelQuery> &res, std::string query)
 
        if (sort == -1)
        {
-               eWarning("ORDER BY .. string invalid.");
+               eWarning("[eDVBChannelQuery] ORDER BY .. string invalid.");
                res = 0;
                return -1;
        }
 
-//     eDebug("sort by %d", sort);
+//     eDebug("[eDVBChannelQuery] sort by %d", sort);
 
                /* now we recursivly parse that. */
        int r = parseExpression(res, tokens.begin(), tokens.end());
@@ -2332,7 +2332,7 @@ RESULT eDVBChannelQuery::compile(ePtr<eDVBChannelQuery> &res, std::string query)
                res->m_bouquet_name = bouquet_name;
        }
 
-//     eDebug("return: %d", r);
+//     eDebug("[eDVBChannelQuery] return: %d", r);
        return r;
 }
 
index 5ec74e0..5979b53 100644 (file)
@@ -31,13 +31,13 @@ eDVBAudio::eDVBAudio(eDVBDemux *demux, int dev)
        sprintf(filename, "/dev/dvb/adapter%d/audio%d", demux ? demux->adapter : 0, dev);
        m_fd = ::open(filename, O_RDWR | O_CLOEXEC);
        if (m_fd < 0)
-               eWarning("%s: %m", filename);
+               eWarning("[eDVBAudio] %s: %m", filename);
        if (demux)
        {
                sprintf(filename, "/dev/dvb/adapter%d/demux%d", demux->adapter, demux->demux);
                m_fd_demux = ::open(filename, O_RDWR | O_CLOEXEC);
                if (m_fd_demux < 0)
-                       eWarning("%s: %m", filename);
+                       eWarning("[eDVBAudio] %s: %m", filename);
        }
        else
        {
@@ -75,14 +75,14 @@ int eDVBAudio::startPid(int pid, int type)
                        break;
                }
                pes.flags    = 0;
-               eDebugNoNewLineStart("DMX_SET_PES_FILTER(0x%02x) - audio%d - ", pid, m_dev);
+               eDebugNoNewLineStart("[eDVBAudio] DMX_SET_PES_FILTER(0x%02x) - audio%d - ", pid, m_dev);
                if (::ioctl(m_fd_demux, DMX_SET_PES_FILTER, &pes) < 0)
                {
                        eDebugNoNewLine("failed (%m)\n");
                        return -errno;
                }
                eDebugNoNewLine("ok\n");
-               eDebugNoNewLineStart("DEMUX_START - audio - ");
+               eDebugNoNewLineStart("[eDVBAudio] DEMUX_START - audio%d - ", m_dev);
                if (::ioctl(m_fd_demux, DMX_START) < 0)
                {
                        eDebugNoNewLine("failed (%m)\n");
@@ -123,13 +123,13 @@ int eDVBAudio::startPid(int pid, int type)
                        break;
                }
 
-               eDebugNoNewLineStart("AUDIO_SET_BYPASS(%d) - ", bypass);
+               eDebugNoNewLineStart("[eDVBAudio] AUDIO_SET_BYPASS(%d) - audio%d", bypass, m_dev);
                if (::ioctl(m_fd, AUDIO_SET_BYPASS_MODE, bypass) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
                        eDebugNoNewLine("ok\n");
                freeze();  // why freeze here?!? this is a problem when only a pid change is requested... because of the unfreeze logic in Decoder::setState
-               eDebugNoNewLineStart("AUDIO_PLAY - ");
+               eDebugNoNewLineStart("[eDVBAudio] AUDIO_PLAY - ");
                if (::ioctl(m_fd, AUDIO_PLAY) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
@@ -140,9 +140,10 @@ int eDVBAudio::startPid(int pid, int type)
 
 void eDVBAudio::stop()
 {
+       eDebug("[eDVBAUDIO] AUDIO_STOP - audio%d", m_dev);
        if (m_fd >= 0)
        {
-               eDebugNoNewLineStart("AUDIO_STOP - ");
+               eDebugNoNewLineStart("[eDVBAUDIO] AUDIO_STOP - audio%d", m_dev);
                if (::ioctl(m_fd, AUDIO_STOP) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
@@ -150,7 +151,7 @@ void eDVBAudio::stop()
        }
        if (m_fd_demux >= 0)
        {
-               eDebugNoNewLineStart("DEMUX_STOP - audio - ");
+               eDebugNoNewLineStart("[eDVBAUDIO] DEMUX_STOP - audio%d - ", m_dev);
                if (::ioctl(m_fd_demux, DMX_STOP) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
@@ -162,7 +163,7 @@ void eDVBAudio::flush()
 {
        if (m_fd >= 0)
        {
-               eDebugNoNewLineStart("AUDIO_CLEAR_BUFFER - ");
+               eDebugNoNewLineStart("[eDVBAUDIO] AUDIO_CLEAR_BUFFER - audio%d ", m_dev);
                if (::ioctl(m_fd, AUDIO_CLEAR_BUFFER) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
@@ -174,7 +175,7 @@ void eDVBAudio::freeze()
 {
        if (m_fd >= 0)
        {
-               eDebugNoNewLineStart("AUDIO_PAUSE - ");
+               eDebugNoNewLineStart("[eDVBAUDIO] AUDIO_PAUSE - audio%d ", m_dev);
                if (::ioctl(m_fd, AUDIO_PAUSE) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
@@ -186,7 +187,7 @@ void eDVBAudio::unfreeze()
 {
        if (m_fd >= 0)
        {
-               eDebugNoNewLineStart("AUDIO_CONTINUE - ");
+               eDebugNoNewLineStart("[eDVBAUDIO] AUDIO_CONTINUE - audio%d ", m_dev);
                if (::ioctl(m_fd, AUDIO_CONTINUE) < 0)
                        eDebugNoNewLine("failed (%m)\n");
                else
index b2a3520..790fe2d 100644 (file)
@@ -116,7 +116,7 @@ eDVBResourceManager::eDVBResourceManager()
        else if (!strncmp(tmp, "dm7020hd\n", rd))
                m_boxtype = DM7020HD;
        else {
-               eDebug("boxtype detection via /proc/stb/info not possible... use fallback via demux count!\n");
+               eDebug("[eDVBResourceManager] boxtype detection via /proc/stb/info not possible... use fallback via demux count!\n");
                if (m_demux.size() == 3)
                        m_boxtype = DM800;
                else if (m_demux.size() < 5)
@@ -125,7 +125,7 @@ eDVBResourceManager::eDVBResourceManager()
                        m_boxtype = DM8000;
        }
 
-       eDebug("found %zd adapter, %zd frontends(%zd sim) and %zd demux, boxtype %d",
+       eDebug("[eDVBResourceManager] found %zd adapter, %zd frontends(%zd sim) and %zd demux, boxtype %d",
                m_adapter.size(), m_frontend.size(), m_simulate_frontend.size(), m_demux.size(), m_boxtype);
 
        CONNECT(m_releaseCachedChannelTimer->timeout, eDVBResourceManager::releaseCachedChannel);
@@ -152,7 +152,7 @@ void eDVBAdapterLinux::scanDevices()
                // scan frontends
        int num_fe = 0;
 
-       eDebug("scanning for frontends..");
+       eDebug("[eDVBResourceManager] scanning for frontends..");
        while (1)
        {
                /*
@@ -375,7 +375,7 @@ eDVBUsbAdapter::eDVBUsbAdapter(int nr)
                goto error;
        }
 
-       eDebug("linking adapter%d/frontend0 to vtuner%d", nr, vtunerid);
+       eDebug("[eDVBUsbAdapter] linking adapter%d/frontend0 to vtuner%d", nr, vtunerid);
 
        switch (fe_info.type)
        {
@@ -392,7 +392,7 @@ eDVBUsbAdapter::eDVBUsbAdapter(int nr)
                strcpy(type,"ATSC");
                break;
        default:
-               eDebug("Frontend type 0x%x not supported", fe_info.type);
+               eDebug("[eDVBUsbAdapter] Frontend type 0x%x not supported", fe_info.type);
                goto error;
        }
 
@@ -684,7 +684,7 @@ PyObject *eDVBResourceManager::setFrontendSlotInformations(ePyObject list)
                }
        }
        if (assigned != m_frontend.size()) {
-               eDebug("eDVBResourceManager::setFrontendSlotInformations .. assigned %zd socket informations, but %d registered frontends!",
+               eDebug("[eDVBResourceManager::setFrontendSlotInformations] .. assigned %zd socket informations, but %d registered frontends!",
                        m_frontend.size(), assigned);
        }
        for (eSmartPtrList<eDVBRegisteredFrontend>::iterator i(m_simulate_frontend.begin()); i != m_simulate_frontend.end(); ++i)
@@ -803,7 +803,7 @@ RESULT eDVBResourceManager::allocateFrontend(ePtr<eDVBAllocatedFrontend> &fe, eP
 
                if (!i->m_inuse)
                {
-//                     eDebug("Slot %d, score %d", i->m_frontend->getSlotID(), c);
+//                     eDebug("[eDVBResourceManager] Slot %d, score %d", i->m_frontend->getSlotID(), c);
                        if (c > bestval)
                        {
                                bestval = c;
@@ -811,7 +811,7 @@ RESULT eDVBResourceManager::allocateFrontend(ePtr<eDVBAllocatedFrontend> &fe, eP
                        }
                }
 //             else
-//                     eDebug("Slot %d, score %d... but BUSY!!!!!!!!!!!", i->m_frontend->getSlotID(), c);
+//                     eDebug("[eDVBResourceManager] Slot %d, score %d... but BUSY!!!!!!!!!!!", i->m_frontend->getSlotID(), c);
        }
 
        if (best)
@@ -842,7 +842,7 @@ RESULT eDVBResourceManager::allocateFrontendByIndex(ePtr<eDVBAllocatedFrontend>
                                eDVBRegisteredFrontend *satpos_depends_to_fe = (eDVBRegisteredFrontend *)tmp;
                                if (satpos_depends_to_fe->m_inuse)
                                {
-                                       eDebug("another satpos depending frontend is in use.. so allocateFrontendByIndex not possible!");
+                                       eDebug("[eDVBResourceManager] another satpos depending frontend is in use.. so allocateFrontendByIndex not possible!");
                                        err = errAllSourcesBusy;
                                        goto alloc_fe_by_id_not_possible;
                                }
@@ -855,7 +855,7 @@ RESULT eDVBResourceManager::allocateFrontendByIndex(ePtr<eDVBAllocatedFrontend>
                                        eDVBRegisteredFrontend *next = (eDVBRegisteredFrontend *) tmp;
                                        if (next->m_inuse)
                                        {
-                                               eDebug("another linked frontend is in use.. so allocateFrontendByIndex not possible!");
+                                               eDebug("[eDVBResourceManager] another linked frontend is in use.. so allocateFrontendByIndex not possible!");
                                                err = errAllSourcesBusy;
                                                goto alloc_fe_by_id_not_possible;
                                        }
@@ -867,7 +867,7 @@ RESULT eDVBResourceManager::allocateFrontendByIndex(ePtr<eDVBAllocatedFrontend>
                                        eDVBRegisteredFrontend *prev = (eDVBRegisteredFrontend *) tmp;
                                        if (prev->m_inuse)
                                        {
-                                               eDebug("another linked frontend is in use.. so allocateFrontendByIndex not possible!");
+                                               eDebug("[eDVBResourceManager] another linked frontend is in use.. so allocateFrontendByIndex not possible!");
                                                err = errAllSourcesBusy;
                                                goto alloc_fe_by_id_not_possible;
                                        }
@@ -888,8 +888,9 @@ RESULT eDVBResourceManager::allocateDemux(eDVBRegisteredFrontend *fe, ePtr<eDVBA
 {
                /* find first unused demux which is on same adapter as frontend (or any, if PVR)
                   never use the first one unless we need a decoding demux. */
+       uint8_t d, a;
 
-       eDebug("allocate demux");
+       eDebug("[eDVBResourceManager] allocate demux");
        eSmartPtrList<eDVBRegisteredDemux>::iterator i(m_demux.begin());
 
        if (i == m_demux.end())
@@ -955,6 +956,9 @@ RESULT eDVBResourceManager::allocateDemux(eDVBRegisteredFrontend *fe, ePtr<eDVBA
                                        /* demux is in use, see if we can share it */
                                        if (source >= 0 && i->m_demux->getSource() == source)
                                        {
+                                               i->m_demux->getCAAdapterID(a);
+                                               i->m_demux->getCADemuxID(d);
+                                               eDebug("[eDVBResourceManager] allocating shared demux adapter=%d, demux=%d, source=%d", a, d, i->m_demux->getSource());
                                                demux = new eDVBAllocatedDemux(i);
                                                return 0;
                                        }
@@ -973,6 +977,9 @@ RESULT eDVBResourceManager::allocateDemux(eDVBRegisteredFrontend *fe, ePtr<eDVBA
 
        if (unused)
        {
+               unused->m_demux->getCAAdapterID(a);
+               unused->m_demux->getCADemuxID(d);
+               eDebug("[eDVBResourceManager] allocating demux adapter=%d, demux=%d, source=%d", a, d, unused->m_demux->getSource());
                demux = new eDVBAllocatedDemux(unused);
                if (fe)
                        demux->get().setSourceFrontend(fe->m_frontend->getDVBID());
@@ -981,7 +988,7 @@ RESULT eDVBResourceManager::allocateDemux(eDVBRegisteredFrontend *fe, ePtr<eDVBA
                return 0;
        }
 
-       eDebug("demux not found");
+       eDebug("[eDVBResourceManager] no free demux found");
        return -1;
 }
 
@@ -1017,7 +1024,7 @@ RESULT eDVBResourceManager::allocateChannel(const eDVBChannelID &channelid, eUse
                eDVBChannel *cache_chan = (eDVBChannel*)&(*m_cached_channel);
                if(channelid==cache_chan->getChannelID())
                {
-                       eDebug("use cached_channel");
+                       eDebug("[eDVBResourceManager] use cached_channel");
                        channel = m_cached_channel;
                        return 0;
                }
@@ -1026,13 +1033,13 @@ RESULT eDVBResourceManager::allocateChannel(const eDVBChannelID &channelid, eUse
                m_releaseCachedChannelTimer->stop();
        }
 
-       eDebugNoSimulate("allocate channel.. %04x:%04x", channelid.transport_stream_id.get(), channelid.original_network_id.get());
+       eDebugNoSimulate("[eDVBResourceManager] allocate channel.. %04x:%04x", channelid.transport_stream_id.get(), channelid.original_network_id.get());
        for (std::list<active_channel>::iterator i(active_channels.begin()); i != active_channels.end(); ++i)
        {
-               eDebugNoSimulate("available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
+               eDebugNoSimulate("[eDVBResourceManager] available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
                if (i->m_channel_id == channelid)
                {
-                       eDebugNoSimulate("found shared channel..");
+                       eDebugNoSimulate("[eDVBResourceManager] found shared channel..");
                        channel = i->m_channel;
                        return 0;
                }
@@ -1042,14 +1049,14 @@ RESULT eDVBResourceManager::allocateChannel(const eDVBChannelID &channelid, eUse
 
        if (!m_list)
        {
-               eDebugNoSimulate("no channel list set!");
+               eDebugNoSimulate("[eDVBResourceManager] no channel list set!");
                return errNoChannelList;
        }
 
        ePtr<iDVBFrontendParameters> feparm;
        if (m_list->getChannelFrontendData(channelid, feparm))
        {
-               eDebugNoSimulate("channel not found!");
+               eDebugNoSimulate("[eDVBResourceManager] channel not found!");
                return errChannelNotInList;
        }
 
@@ -1092,13 +1099,13 @@ void eDVBResourceManager::DVBChannelStateChanged(iDVBChannel *chan)
                case iDVBChannel::state_release:
                case iDVBChannel::state_ok:
                {
-                       eDebug("stop release channel timer");
+                       eDebug("[eDVBResourceManager] stop release channel timer");
                        m_releaseCachedChannelTimer->stop();
                        break;
                }
                case iDVBChannel::state_last_instance:
                {
-                       eDebug("start release channel timer");
+                       eDebug("[eDVBResourceManager] start release channel timer");
                        m_releaseCachedChannelTimer->start(3000, true);
                        break;
                }
@@ -1109,7 +1116,7 @@ void eDVBResourceManager::DVBChannelStateChanged(iDVBChannel *chan)
 
 void eDVBResourceManager::releaseCachedChannel()
 {
-       eDebug("release cached channel (timer timeout)");
+       eDebug("[eDVBResourceManager] release cached channel (timer timeout)");
        m_cached_channel=0;
 }
 
@@ -1265,13 +1272,13 @@ int eDVBResourceManager::canAllocateChannel(const eDVBChannelID &channelid, cons
        }
 
                /* first, check if a channel is already existing. */
-//     eDebug("allocate channel.. %04x:%04x", channelid.transport_stream_id.get(), channelid.original_network_id.get());
+//     eDebug("[eDVBResourceManager] allocate channel.. %04x:%04x", channelid.transport_stream_id.get(), channelid.original_network_id.get());
        for (std::list<active_channel>::iterator i(active_channels.begin()); i != active_channels.end(); ++i)
        {
-//             eDebug("available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
+//             eDebug("[eDVBResourceManager] available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
                if (i->m_channel_id == channelid)
                {
-//                     eDebug("found shared channel..");
+//                     eDebug("[eDVBResourceManager] found shared channel..");
                        return tuner_type_channel_default(m_list, channelid, system);
                }
        }
@@ -1282,7 +1289,7 @@ int eDVBResourceManager::canAllocateChannel(const eDVBChannelID &channelid, cons
        for (std::list<active_channel>::iterator i(active_channels.begin()); i != active_channels.end(); ++i)
        {
                eSmartPtrList<eDVBRegisteredFrontend> &frontends = simulate ? m_simulate_frontend : m_frontend;
-//             eDebug("available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
+//             eDebug("[eDVBResourceManager] available channel.. %04x:%04x", i->m_channel_id.transport_stream_id.get(), i->m_channel_id.original_network_id.get());
                if (i->m_channel_id == ignore)
                {
                        eDVBChannel *channel = (eDVBChannel*) &(*i->m_channel);
@@ -1343,13 +1350,13 @@ int eDVBResourceManager::canAllocateChannel(const eDVBChannelID &channelid, cons
 
        if (!m_list)
        {
-               eDebug("no channel list set!");
+               eDebug("[eDVBResourceManager] no channel list set!");
                goto error;
        }
 
        if (m_list->getChannelFrontendData(channelid, feparm))
        {
-               eDebug("channel not found!");
+               eDebug("[eDVBResourceManager] channel not found!");
                goto error;
        }
        feparm->getSystem(system);
@@ -1463,24 +1470,24 @@ void eDVBChannel::frontendStateChanged(iDVBFrontend*fe)
 
        if (state == iDVBFrontend::stateLock)
        {
-               eDebug("OURSTATE: ok");
+               eDebug("[eDVBChannel] OURSTATE: ok");
                ourstate = state_ok;
        } else if (state == iDVBFrontend::stateTuning)
        {
-               eDebug("OURSTATE: tuning");
+               eDebug("[eDVBChannel] OURSTATE: tuning");
                ourstate = state_tuning;
        } else if (state == iDVBFrontend::stateLostLock)
        {
                        /* on managed channels, we try to retune in order to re-acquire lock. */
                if (m_current_frontend_parameters)
                {
-                       eDebug("OURSTATE: lost lock, trying to retune");
+                       eDebug("[eDVBChannel] OURSTATE: lost lock, trying to retune");
                        ourstate = state_tuning;
                        m_frontend->get().tune(*m_current_frontend_parameters);
                } else
                        /* on unmanaged channels, we don't do this. the client will do this. */
                {
-                       eDebug("OURSTATE: lost lock, unavailable now.");
+                       eDebug("[eDVBChannel] OURSTATE: lost lock, unavailable now.");
                        ourstate = state_unavailable;
                }
        } else if (state == iDVBFrontend::stateFailed)
@@ -1489,14 +1496,14 @@ void eDVBChannel::frontendStateChanged(iDVBFrontend*fe)
                        /* on managed channels, we do a retry */
                if (m_current_frontend_parameters)
                {
-                       eDebug("OURSTATE: failed, retune");
+                       eDebug("[eDVBChannel] OURSTATE: failed, retune");
                        m_frontend->get().tune(*m_current_frontend_parameters);
                } else
                { /* nothing we can do */
-                       eDebug("OURSTATE: failed, fatal");
+                       eDebug("[eDVBChannel] OURSTATE: failed, fatal");
                }
        } else
-               eFatal("state unknown");
+               eFatal("[eDVBChannel] state unknown");
 
        if (ourstate != m_state)
        {
@@ -1510,15 +1517,15 @@ void eDVBChannel::pvrEvent(int event)
        switch (event)
        {
        case eFilePushThread::evtEOF:
-               eDebug("eDVBChannel: End of file!");
+               eDebug("[eDVBChannel] End of file!");
                m_event(this, evtEOF);
                break;
        case eFilePushThread::evtUser: /* start */
-               eDebug("SOF");
+               eDebug("[eDVBChannel] SOF");
                m_event(this, evtSOF);
                break;
        case eFilePushThread::evtStopped:
-               eDebug("eDVBChannel: pvrEvent evtStopped");
+               eDebug("[eDVBChannel] pvrEvent evtStopped");
                m_event(this, evtStopped);
                break;
        }
@@ -1532,7 +1539,7 @@ void eDVBChannel::cueSheetEvent(int event)
        switch (event)
        {
        case eCueSheet::evtSeek:
-               eDebug("seek.");
+               eDebug("[eDVBChannel] seek.");
                flushPVR(m_cue->m_decoding_demux);
                break;
        case eCueSheet::evtSkipmode:
@@ -1547,7 +1554,7 @@ void eDVBChannel::cueSheetEvent(int event)
                                m_tstools_lock.lock();
                                int bitrate = m_tstools.calcBitrate(); /* in bits/s */
                                m_tstools_lock.unlock();
-                               eDebug("skipmode ratio is %lld:90000, bitrate is %d bit/s", m_cue->m_skipmode_ratio, bitrate);
+                               eDebug("[eDVBChannel] skipmode ratio is %lld:90000, bitrate is %d bit/s", m_cue->m_skipmode_ratio, bitrate);
                                                /* i agree that this might look a bit like black magic. */
                                m_skipmode_n = 512*1024; /* must be 1 iframe at least. */
                                m_skipmode_m = bitrate / 8 / 90000 * m_cue->m_skipmode_ratio / 8;
@@ -1557,16 +1564,16 @@ void eDVBChannel::cueSheetEvent(int event)
                                if (m_cue->m_skipmode_ratio < 0)
                                        m_skipmode_m -= m_skipmode_n;
 
-                               eDebug("resolved to: %d %d", m_skipmode_m, m_skipmode_n);
+                               eDebug("[eDVBChannel] resolved to: %d %d", m_skipmode_m, m_skipmode_n);
 
                                if (abs(m_skipmode_m) < abs(m_skipmode_n))
                                {
-                                       eWarning("something is wrong with this calculation");
+                                       eWarning("[eDVBChannel] something is wrong with this cueSheetEvent calculation");
                                        m_skipmode_frames = m_skipmode_n = m_skipmode_m = 0;
                                }
                        } else
                        {
-                               eDebug("skipmode ratio is 0, normal play");
+                               eDebug("[eDVBChannel] skipmode ratio is 0, normal play");
                                m_skipmode_frames = m_skipmode_n = m_skipmode_m = 0;
                        }
                }
@@ -1575,9 +1582,9 @@ void eDVBChannel::cueSheetEvent(int event)
                        m_pvr_thread->setTimebaseChange(0x10000 * 9000 / (m_cue->m_skipmode_ratio / 10)); /* negative values are also ok */
                else
                        m_pvr_thread->setTimebaseChange(0); /* normal playback */
-               eDebug("flush pvr");
+               eDebug("[eDVBChannel] flush pvr");
                flushPVR(m_cue->m_decoding_demux);
-               eDebug("done");
+               eDebug("[eDVBChannel] done");
                break;
        }
        case eCueSheet::evtSpanChanged:
@@ -1592,10 +1599,10 @@ void eDVBChannel::cueSheetEvent(int event)
                        m_tstools_lock.unlock();
                        if (r)
                        {
-                               eDebug("span translation failed.\n");
+                               eDebug("[eDVBChannel] span translation failed.\n");
                                continue;
                        }
-                       eDebug("source span: %llu .. %llu, translated to %llu..%llu", pts_in, pts_out, offset_in, offset_out);
+                       eDebug("[eDVBChannel] source span: %llu .. %llu, translated to %llu..%llu", pts_in, pts_out, offset_in, offset_out);
                        m_source_span.push_back(std::pair<off_t, off_t>(offset_in, offset_out));
                }
                break;
@@ -1633,7 +1640,7 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
 
        if (!m_cue)
        {
-               eDebug("no cue sheet. forcing normal play");
+               eDebug("[eDVBChannel] no cue sheet. forcing normal play");
                start = current_offset;
                size = max;
                return;
@@ -1644,13 +1651,13 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                max = align(m_skipmode_n, blocksize);
        }
 
-       //eDebug("getNextSourceSpan, current offset is %08llx, m_skipmode_m = %d!", current_offset, m_skipmode_m);
+       //eDebug("[eDVBChannel] getNextSourceSpan, current offset is %08llx, m_skipmode_m = %d!", current_offset, m_skipmode_m);
        int frame_skip_success = 0;
 
        if (m_skipmode_m)
        {
                int frames_to_skip = m_skipmode_frames + m_skipmode_frames_remainder;
-               //eDebug("we are at %llu, and we try to skip %d+%d frames from here", current_offset, m_skipmode_frames, m_skipmode_frames_remainder);
+               //eDebug("[eDVBChannel] we are at %llu, and we try to skip %d+%d frames from here", current_offset, m_skipmode_frames, m_skipmode_frames_remainder);
                size_t iframe_len;
                off_t iframe_start = current_offset;
                int frames_skipped = frames_to_skip;
@@ -1660,14 +1667,14 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                if (!r)
                {
                        m_skipmode_frames_remainder = frames_to_skip - frames_skipped;
-                       //eDebug("successfully skipped %d (out of %d, rem now %d) frames.", frames_skipped, frames_to_skip, m_skipmode_frames_remainder);
+                       //eDebug("[eDVBChannel] successfully skipped %d (out of %d, rem now %d) frames.", frames_skipped, frames_to_skip, m_skipmode_frames_remainder);
                        current_offset = align(iframe_start, blocksize);
                        max = align(iframe_len + 187, blocksize);
                        frame_skip_success = 1;
                } else
                {
                        m_skipmode_frames_remainder = 0;
-                       eDebug("frame skipping failed, reverting to byte-skipping");
+                       eDebug("[eDVBChannel] frame skipping failed, reverting to byte-skipping");
                }
        }
 
@@ -1677,7 +1684,7 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
 
                if (m_skipmode_m)
                {
-                       eDebug("we are at %llu, and we try to find the iframe here:", current_offset);
+                       eDebug("[eDVBChannel] we are at %llu, and we try to find the iframe here:", current_offset);
                        size_t iframe_len;
                        off_t iframe_start = current_offset;
 
@@ -1686,7 +1693,7 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                        int r = m_tstools.findFrame(iframe_start, iframe_len, direction);
                        m_tstools_lock.unlock();
                        if (r)
-                               eDebug("failed");
+                               eDebug("[eDVBChannel] failed");
                        else
                        {
                                current_offset = align(iframe_start, blocksize);
@@ -1712,24 +1719,24 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                {
                        if (!m_cue->m_decoder)
                        {
-                               eDebug("no decoder - can't seek relative");
+                               eDebug("[eDVBChannel] no decoder - can't seek relative");
                                continue;
                        }
                        if (m_cue->m_decoder->getPTS(0, now))
                        {
-                               eDebug("decoder getPTS failed, can't seek relative");
+                               eDebug("[eDVBChannel] decoder getPTS failed, can't seek relative");
                                continue;
                        }
                        if (!m_cue->m_decoding_demux)
                        {
-                               eDebug("getNextSourceSpan, no decoding demux. couldn't seek to %llu... ignore request!", pts);
+                               eDebug("[eDVBChannel] getNextSourceSpan, no decoding demux. couldn't seek to %llu... ignore request!", pts);
                                start = current_offset;
                                size = max;
                                continue;
                        }
                        if (getCurrentPosition(m_cue->m_decoding_demux, now, 1))
                        {
-                               eDebug("seekTo: getCurrentPosition failed!");
+                               eDebug("[eDVBChannel] seekTo: getCurrentPosition failed!");
                                continue;
                        }
                } else if (pts < 0) /* seek relative to end */
@@ -1737,11 +1744,11 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                        pts_t len;
                        if (!getLength(len))
                        {
-                               eDebug("seeking relative to end. len=%lld, seek = %lld", len, pts);
+                               eDebug("[eDVBChannel] seeking relative to end. len=%lld, seek = %lld", len, pts);
                                pts += len;
                        } else
                        {
-                               eWarning("getLength failed - can't seek relative to end!");
+                               eWarning("[eDVBChannel] getLength failed - can't seek relative to end!");
                                continue;
                        }
                }
@@ -1759,17 +1766,17 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
 
                if (relative == 2) /* AP relative */
                {
-                       eDebug("AP relative seeking: %lld, at %lld", pts, now);
+                       eDebug("[eDVBChannel] AP relative seeking: %lld, at %lld", pts, now);
                        pts_t nextap;
                        eSingleLocker l(m_tstools_lock);
                        if (m_tstools.getNextAccessPoint(nextap, now, pts))
                        {
                                pts = now - 90000; /* approx. 1s */
-                               eDebug("AP relative seeking failed!");
+                               eDebug("[eDVBChannel] AP relative seeking failed!");
                        } else
                        {
                                pts = nextap;
-                               eDebug("next ap is %llu\n", pts);
+                               eDebug("[eDVBChannel] next ap is %llu\n", pts);
                        }
                }
 
@@ -1779,11 +1786,11 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                m_tstools_lock.unlock();
                if (r)
                {
-                       eDebug("get offset for pts=%llu failed!", pts);
+                       eDebug("[eDVBChannel] get offset for pts=%llu failed!", pts);
                        continue;
                }
 
-               eDebug("ok, resolved skip (rel: %d, diff %lld), now at %08llx", relative, pts, offset);
+               eDebug("[eDVBChannel] ok, resolved skip (rel: %d, diff %lld), now at %08llx", relative, pts, offset);
                current_offset = align(offset, blocksize); /* in case tstools return non-aligned offset */
        }
 
@@ -1797,7 +1804,7 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                        {
                                start = current_offset;
                                size = diff_upto(i->second, start, max);
-                               //eDebug("HIT, %lld < %lld < %lld, size: %zd", i->first, current_offset, i->second, size);
+                               //eDebug("[eDVBChannel] HIT, %lld < %lld < %lld, size: %zd", i->first, current_offset, i->second, size);
                                return;
                        }
                }
@@ -1809,10 +1816,10 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                                        /* in normal playback, just start at the next zone. */
                                start = i->first;
                                size = diff_upto(i->second, start, max);
-                               eDebug("skip");
+                               eDebug("[eDVBChannel] skip");
                                if (m_skipmode_m < 0)
                                {
-                                       eDebug("reached SOF");
+                                       eDebug("[eDVBChannel] reached SOF");
                                        m_skipmode_m = 0;
                                        m_pvr_thread->sendEvent(eFilePushThread::evtUser);
                                }
@@ -1821,20 +1828,20 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
                                        /* when skipping reverse, however, choose the zone before. */
                                        /* This returns a size 0 block, in case you noticed... */
                                --i;
-                               eDebug("skip to previous block, which is %llu..%llu", i->first, i->second);
+                               eDebug("[eDVBChannel] skip to previous block, which is %llu..%llu", i->first, i->second);
                                size_t len = diff_upto(i->second, i->first, max);
                                start = i->second - len;
-                               eDebug("skipping to %llu, %zd", start, len);
+                               eDebug("[eDVBChannel] skipping to %llu, %zd", start, len);
                        }
 
-                       eDebug("result: %llu, %zx (%llu %llu)", start, size, i->first, i->second);
+                       eDebug("[eDVBChannel] result: %llu, %zx (%llu %llu)", start, size, i->first, i->second);
                        return;
                }
        }
 
        if ((current_offset < -m_skipmode_m) && (m_skipmode_m < 0))
        {
-               eDebug("reached SOF");
+               eDebug("[eDVBChannel] reached SOF");
                m_skipmode_m = 0;
                m_pvr_thread->sendEvent(eFilePushThread::evtUser);
        }
@@ -1843,7 +1850,7 @@ void eDVBChannel::getNextSourceSpan(off_t current_offset, size_t bytes_read, off
        if (m_source_span.empty())
        {
                size = max;
-               // eDebug("NO CUESHEET. (%08llx, %zd)", start, size);
+               // eDebug("[eDVBChannel] NO CUESHEET. (%08llx, %zd)", start, size);
        } else
        {
                size = 0;
@@ -2040,7 +2047,7 @@ RESULT eDVBChannel::playFile(const char *file)
 
        if (f->open(file) < 0)
        {
-               eDebug("can't open PVR file %s (%m)", file);
+               eDebug("[eDVBChannel] can't open PVR file %s (%m)", file);
                return -ENOENT;
        }
 
@@ -2059,7 +2066,7 @@ RESULT eDVBChannel::playSource(ePtr<iTsSource> &source, const char *streaminfo_f
 
        if (!source->valid() && !source->isStream())
        {
-               eDebug("PVR source is not valid!");
+               eDebug("[eDVBChannel] PVR source is not valid!");
                return -ENOENT;
        }
 
@@ -2076,7 +2083,7 @@ RESULT eDVBChannel::playSource(ePtr<iTsSource> &source, const char *streaminfo_f
                m_pvr_fd_dst = open("/dev/misc/pvr", O_WRONLY);
                if (m_pvr_fd_dst < 0)
                {
-                       eDebug("can't open /dev/misc/pvr - %m"); // or wait for the driver to be improved.
+                       eDebug("[eDVBChannel] can't open /dev/misc/pvr - %m"); // or wait for the driver to be improved.
                        return -ENODEV;
                }
 #else
@@ -2086,13 +2093,13 @@ RESULT eDVBChannel::playSource(ePtr<iTsSource> &source, const char *streaminfo_f
                        m_pvr_fd_dst = demux->get().openDVR(O_WRONLY);
                        if (m_pvr_fd_dst < 0)
                        {
-                               eDebug("can't open /dev/dvb/adapterX/dvrX - you need to buy the new(!) $$$ box! (%m)"); // or wait for the driver to be improved.
+                               eDebug("[eDVBChannel] can't open /dev/dvb/adapterX/dvrX - you need to buy the new(!) $$$ box! (%m)"); // or wait for the driver to be improved.
                                return -ENODEV;
                        }
                }
                else
                {
-                       eDebug("no demux allocated yet.. so its not possible to open the dvr device!!");
+                       eDebug("[eDVBChannel] no demux allocated yet.. so its not possible to open the dvr device!!");
                        return -ENODEV;
                }
 #endif
@@ -2166,7 +2173,7 @@ RESULT eDVBChannel::getCurrentPosition(iDVBDemux *decoding_demux, pts_t &pos, in
                r = decoding_demux->getSTC(now, 0);
                if (r)
                {
-                       eDebug("demux getSTC failed");
+                       eDebug("[eDVBChannel] demux getSTC failed");
                        return -1;
                }
        } else
index 8bbbcff..07603e8 100644 (file)
@@ -137,18 +137,22 @@ void eDVBVolumecontrol::setVolume(int left, int right)
        mixer.volume_left = left;
        mixer.volume_right = right;
 
-       eDebug("Setvolume: %d %d (raw)", leftVol, rightVol);
-       eDebug("Setvolume: %d %d (-1db)", left, right);
+       eDebug("Setvolume: raw: %d %d, -1db: %d %d", leftVol, rightVol, left, right);
 
        int fd = openMixer();
        if (fd >= 0)
        {
 #ifdef HAVE_DVB_API_VERSION
-               ioctl(fd, AUDIO_SET_MIXER, &mixer);
+               if (ioctl(fd, AUDIO_SET_MIXER, &mixer) < 0) {
+                       eDebug("Setvolume: failed %m");
+               }
 #endif
                closeMixer(fd);
                return;
        }
+       else {
+               eDebug("SetVolume: failed to open mixer");
+       }
 
        //HACK?
        CFile::writeInt("/proc/stb/avs/0/volume", left); /* in -1dB */
index d4bd9a1..11fd525 100644 (file)
@@ -90,7 +90,7 @@ int eStaticServiceDVBInformation::isPlayable(const eServiceReference &ref, const
 {
        ePtr<eDVBResourceManager> res_mgr;
        if ( eDVBResourceManager::getInstance( res_mgr ) )
-               eDebug("eStaticServiceDVBInformation: isPlayable... no res manager!!");
+               eDebug("[eStaticServiceDVBInformation] isPlayable... no res manager!!");
        else
        {
                eDVBChannelID chid, chid_ignore;
@@ -153,7 +153,7 @@ ePtr<iDVBTransponderData> eStaticServiceDVBInformation::getTransponderData(const
                                                                break;
                                                        }
                                                        default:
-                                                               eDebug("eStaticServiceDVBInformation: unknown frontend type %d", system);
+                                                               eDebug("[eStaticServiceDVBInformation] unknown frontend type %d", system);
                                                                break;
                                                }
                                        }
@@ -174,19 +174,19 @@ RESULT eStaticServiceDVBBouquetInformation::getName(const eServiceReference &ref
        int err;
        if ((err = eDVBResourceManager::getInstance(res)) != 0)
        {
-               eDebug("eStaticServiceDVBBouquetInformation::getName failed.. no resource manager!");
+               eDebug("[eStaticServiceDVBBouquetInformation::getName] failed.. no resource manager!");
                return err;
        }
        if ((err = res->getChannelList(db)) != 0)
        {
-               eDebug("eStaticServiceDVBBouquetInformation::getName failed.. no channel list!");
+               eDebug("[eStaticServiceDVBBouquetInformation::getName] failed.. no channel list!");
                return err;
        }
 
        eBouquet *bouquet=0;
        if ((err = db->getBouquet(ref, bouquet)) != 0)
        {
-               eDebug("eStaticServiceDVBBouquetInformation::getName failed.. getBouquet failed!");
+               eDebug("[eStaticServiceDVBBouquetInformation::getName] failed.. getBouquet failed!");
                return -1;
        }
 
@@ -209,20 +209,20 @@ int eStaticServiceDVBBouquetInformation::isPlayable(const eServiceReference &ref
 
                if (eDVBResourceManager::getInstance(res))
                {
-                       eDebug("eStaticServiceDVBBouquetInformation::isPlayable failed.. no resource manager!");
+                       eDebug("[eStaticServiceDVBBouquetInformation::isPlayable] failed.. no resource manager!");
                        return 0;
                }
 
                if (res->getChannelList(db))
                {
-                       eDebug("eStaticServiceDVBBouquetInformation::isPlayable failed.. no channel list!");
+                       eDebug("[eStaticServiceDVBBouquetInformation::isPlayable] failed.. no channel list!");
                        return 0;
                }
 
                eBouquet *bouquet=0;
                if (db->getBouquet(ref, bouquet))
                {
-                       eDebug("eStaticServiceDVBBouquetInformation::isPlayable failed.. getBouquet failed!");
+                       eDebug("[eStaticServiceDVBBouquetInformation::isPlayable] failed.. getBouquet failed!");
                        return 0;
                }
 
@@ -521,11 +521,11 @@ RESULT eDVBPVRServiceOfflineOperations::deleteFromDisk(int simulate)
 
                eBackgroundFileEraser *eraser = eBackgroundFileEraser::getInstance();
                if (!eraser)
-                       eDebug("eDVBPVRServiceOfflineOperations::deleteFromDisk: FATAL !! can't get background file eraser");
+                       eDebug("[eDVBPVRServiceOfflineOperations::deleteFromDisk] FATAL !! can't get background file eraser");
 
                for (std::list<std::string>::iterator i(res.begin()); i != res.end(); ++i)
                {
-                       eDebug("eDVBPVRServiceOfflineOperations::deleteFromDisk: Removing %s...", i->c_str());
+                       eDebug("[eDVBPVRServiceOfflineOperations::deleteFromDisk] Removing %s...", i->c_str());
                        if (eraser)
                                eraser->erase(*i);
                        else
@@ -583,20 +583,20 @@ static int reindex_work(const std::string& filename)
                err = tstools.findPMT(program);
                if (err)
                {
-                       eDebug("eDVBPVRServiceOfflineOperations:: reindex - Failed to find PMT");
+                       eDebug("[eDVBPVRServiceOfflineOperations] reindex - Failed to find PMT");
                        return err;
                }
                for (i = 0; i < program.videoStreams.size(); i++)
                {
                        if (timingpidset) break;
-                       eDebug("eDVBPVRServiceOfflineOperations:: reindex: video pid=0x%x", program.videoStreams[i].pid);
+                       eDebug("[eDVBPVRServiceOfflineOperations] reindex: video pid=0x%x", program.videoStreams[i].pid);
                        parser.setPid(program.videoStreams[i].pid, iDVBTSRecorder::video_pid, program.videoStreams[i].type);
                        timingpidset = true;
                }
                for (i = 0; i < program.audioStreams.size(); i++)
                {
                        if (timingpidset) break;
-                       eDebug("eDVBPVRServiceOfflineOperations:: reindex: audio pid=0x%x", program.audioStreams[i].pid);
+                       eDebug("[eDVBPVRServiceOfflineOperations] reindex: audio pid=0x%x", program.audioStreams[i].pid);
                        parser.setPid(program.audioStreams[i].pid, iDVBTSRecorder::audio_pid, program.audioStreams[i].type);
                        timingpidset = true;
                }
@@ -684,12 +684,12 @@ RESULT eDVBServiceList::startQuery()
        int err;
        if ((err = eDVBResourceManager::getInstance(res)) != 0)
        {
-               eDebug("eDVBServiceList: no resource manager");
+               eDebug("[eDVBServiceList] no resource manager");
                return err;
        }
        if ((err = res->getChannelList(db)) != 0)
        {
-               eDebug("eDVBServiceList: no channel list");
+               eDebug("[eDVBServiceList] no channel list");
                return err;
        }
 
@@ -700,14 +700,14 @@ RESULT eDVBServiceList::startQuery()
                eDVBChannelQuery::compile(q, m_parent.path);
                if (!q)
                {
-                       eDebug("eDVBServiceList: compile query failed");
+                       eDebug("[eDVBServiceList] compile query failed");
                        return err;
                }
        }
 
        if ((err = db->startQuery(m_query, q, m_parent)) != 0)
        {
-               eDebug("eDVBServiceList: startQuery failed");
+               eDebug("[eDVBServiceList] startQuery failed");
                return err;
        }
 
@@ -998,12 +998,12 @@ RESULT eServiceFactoryDVB::lookupService(ePtr<eDVBService> &service, const eServ
                int err;
                if ((err = eDVBResourceManager::getInstance(res)) != 0)
                {
-                       eDebug("eServiceFactoryDVB: no resource manager");
+                       eDebug("[eServiceFactoryDVB] no resource manager");
                        return err;
                }
                if ((err = res->getChannelList(db)) != 0)
                {
-                       eDebug("eServiceFactoryDVB: no channel list");
+                       eDebug("[eServiceFactoryDVB] no channel list");
                        return err;
                }
 
@@ -1086,9 +1086,9 @@ void eDVBServicePlay::gotNewEvent(int error)
        getEvent(event_next, 1);
 
        if (event_now)
-               eDebug("eDVBServicePlay: now running: %s (%d seconds :)", event_now->m_event_name.c_str(), event_now->m_duration);
+               eDebug("[eDVBServicePlay] now running: %s (%d seconds :)", event_now->m_event_name.c_str(), event_now->m_duration);
        if (event_next)
-               eDebug("eDVBServicePlay: next running: %s (%d seconds :)", event_next->m_event_name.c_str(), event_next->m_duration);
+               eDebug("[eDVBServicePlay] next running: %s (%d seconds :)", event_next->m_event_name.c_str(), event_next->m_duration);
 #endif
        if (!error)
        {
@@ -1110,7 +1110,7 @@ void eDVBServicePlay::gotNewEvent(int error)
                if (m_record)
                {
                        if (m_record->getCurrentPCR(now_pts))
-                               eDebug("eDVBServicePlay: getting current PTS failed!");
+                               eDebug("[eDVBServicePlay] getting current PTS failed!");
                        else
                        {
                                if (m_record->getFirstPTS(first_pts))
@@ -1121,7 +1121,7 @@ void eDVBServicePlay::gotNewEvent(int error)
                                        fixup_pts = now_pts - first_pts;
                                m_cue_entries.insert(cueEntry(fixup_pts, 2));
                                m_cuesheet_changed = 1;
-                               eDebug("eDVBServicePlay: pts of eit change: %llx, fixup_pts: %llx, first_pts: %llx", now_pts, fixup_pts, first_pts);
+                               eDebug("[eDVBServicePlay] pts of eit change: %llx, fixup_pts: %llx, first_pts: %llx", now_pts, fixup_pts, first_pts);
                                m_event((iPlayableService*)this, evCuesheetChanged);
                        }
                }
@@ -1205,13 +1205,13 @@ void eDVBServicePlay::serviceEvent(int event)
        case eDVBServicePMTHandler::eventTuneFailed:
        case eDVBServicePMTHandler::eventMisconfiguration:
        {
-               eDebug("eDVBServicePlay: DVB service failed to tune - error %d", event);
+               eDebug("[eDVBServicePlay] DVB service failed to tune - error %d", event);
                m_event((iPlayableService*)this, evTuneFailed);
                break;
        }
        case eDVBServicePMTHandler::eventNewProgramInfo:
        {
-               eDebug("eDVBServicePlay: eventNewProgramInfo %d %d", m_timeshift_enabled, m_timeshift_active);
+               eDebug("[eDVBServicePlay] eventNewProgramInfo timeshift_enabled=%d timeshift_active=%d", m_timeshift_enabled, m_timeshift_active);
                if (m_timeshift_enabled)
                        updateTimeshiftPids();
                if (!m_timeshift_active)
@@ -1247,7 +1247,7 @@ void eDVBServicePlay::serviceEventTimeshift(int event)
        switch (event)
        {
        case eDVBServicePMTHandler::eventNewProgramInfo:
-               eDebug("eDVBServicePlay: eventNewProgramInfo TS");
+               eDebug("[eDVBServicePlay] eventNewProgramInfo TimeshiftS");
                if (m_timeshift_active)
                {
                        updateDecoder();
@@ -1255,12 +1255,12 @@ void eDVBServicePlay::serviceEventTimeshift(int event)
                        {
                                if (m_slowmotion)
                                {
-                                       eDebug("eDVBServicePlay: re-apply slowmotion after timeshift file change");
+                                       eDebug("[eDVBServicePlay] re-apply slowmotion after timeshift file change");
                                        m_decoder->setSlowMotion(m_slowmotion);
                                }
                                if (m_fastforward)
                                {
-                                       eDebug("eDVBServicePlay: re-apply skip %d, ratio %d after timeshift file change", m_skipmode, m_fastforward);
+                                       eDebug("[eDVBServicePlay] re-apply skip %d, ratio %d after timeshift file change", m_skipmode, m_fastforward);
                                        if (m_skipmode)
                                                m_cue->setSkipmode(m_skipmode * 90000); /* convert to 90000 per second */
                                        if (m_fastforward != 1)
@@ -1279,7 +1279,7 @@ void eDVBServicePlay::serviceEventTimeshift(int event)
 #if 0
                if (!m_timeshift_file_next.empty())
                {
-                       eDebug("eDVBServicePlay: timeshift SOF, switch to next file");
+                       eDebug("[eDVBServicePlay] timeshift SOF, switch to next file");
                        m_decoder->pause();
 
                        m_first_program_info |= 2;
@@ -1307,12 +1307,12 @@ void eDVBServicePlay::serviceEventTimeshift(int event)
                {
                        if (m_timeshift_file_next.empty())
                        {
-                               eDebug("eDVBServicePlay: timeshift EOF, so let's go live");
+                               eDebug("[eDVBServicePlay] timeshift EOF, so let's go live");
                                switchToLive();
                        }
                        else
                        {
-                               eDebug("eDVBServicePlay: timeshift EOF, switch to next file");
+                               eDebug("[eDVBServicePlay] timeshift EOF, switch to next file");
 
                                m_first_program_info |= 2;
 
@@ -1509,7 +1509,7 @@ RESULT eDVBServicePlay::setSlowMotion(int ratio)
 {
        int ret = 0;
        ASSERT(ratio); /* The API changed: instead of calling setSlowMotion(0), call play! */
-       eDebug("eDVBServicePlay::setSlowMotion(%d)", ratio);
+       eDebug("[eDVBServicePlay::setSlowMotion] %d", ratio);
        setFastForward_internal(0);
        if (m_decoder)
        {
@@ -1524,7 +1524,7 @@ RESULT eDVBServicePlay::setSlowMotion(int ratio)
 
 RESULT eDVBServicePlay::setFastForward(int ratio)
 {
-       eDebug("eDVBServicePlay::setFastForward(%d)", ratio);
+       eDebug("[eDVBServicePlay::setFastForward] %d", ratio);
        ASSERT(ratio);
        return setFastForward_internal(ratio);
 }
@@ -1554,7 +1554,7 @@ RESULT eDVBServicePlay::setFastForward_internal(int ratio, bool final_seek)
 
        if (m_skipmode != skipmode)
        {
-               eDebug("eDVBServicePlay::setFastForward: setting cue skipmode to %d", skipmode);
+               eDebug("[eDVBServicePlay::setFastForward] setting cue skipmode to %d", skipmode);
                if (m_cue)
                        m_cue->setSkipmode(skipmode * 90000); /* convert to 90000 per second */
        }
@@ -1562,7 +1562,7 @@ RESULT eDVBServicePlay::setFastForward_internal(int ratio, bool final_seek)
        m_skipmode = skipmode;
 
        if (final_seek)
-               eDebug("eDVBServicePlay::setFastForward: trickplay stopped .. ret %d, pos %lld", getPlayPosition(pos), pos);
+               eDebug("[eDVBServicePlay::setFastForward] trickplay stopped .. ret %d, pos %lld", getPlayPosition(pos), pos);
 
        m_fastforward = ffratio;
 
@@ -1577,7 +1577,7 @@ RESULT eDVBServicePlay::setFastForward_internal(int ratio, bool final_seek)
                ret = m_decoder->setTrickmode();
 
        if (pos)
-               eDebug("eDVBServicePlay::setFastForward: final seek after trickplay ret %d", seekTo(pos));
+               eDebug("[eDVBServicePlay::setFastForward] final seek after trickplay ret %d", seekTo(pos));
 
        return ret;
 }
@@ -1607,7 +1607,7 @@ RESULT eDVBServicePlay::getLength(pts_t &len)
 
 RESULT eDVBServicePlay::pause()
 {
-       eDebug("eDVBServicePlay::pause");
+       eDebug("[eDVBServicePlay] pause");
        setFastForward_internal(0, m_slowmotion || m_fastforward > 1);
        if (m_decoder)
        {
@@ -1620,7 +1620,7 @@ RESULT eDVBServicePlay::pause()
 
 RESULT eDVBServicePlay::unpause()
 {
-       eDebug("eDVBServicePlay::unpause");
+       eDebug("[eDVBServicePlay] unpause");
        setFastForward_internal(0, m_slowmotion || m_fastforward > 1);
        if (m_decoder)
        {
@@ -1633,7 +1633,7 @@ RESULT eDVBServicePlay::unpause()
 
 RESULT eDVBServicePlay::seekTo(pts_t to)
 {
-       eDebug("eDVBServicePlay::seekTo: jump %lld", to);
+       eDebug("[eDVBServicePlay::seekTo] jump %lld", to);
 
        if (!m_decode_demux)
                return -1;
@@ -1655,7 +1655,7 @@ RESULT eDVBServicePlay::seekTo(pts_t to)
 
 RESULT eDVBServicePlay::seekRelative(int direction, pts_t to)
 {
-       eDebug("eDVBServicePlay::seekRelative: jump %d, %lld", direction, to);
+       eDebug("[eDVBServicePlay::seekRelative] jump %d, %lld", direction, to);
 
        if (!m_decode_demux)
                return -1;
@@ -1750,6 +1750,7 @@ RESULT eDVBServicePlay::subServices(ePtr<iSubserviceList> &ptr)
 RESULT eDVBServicePlay::timeshift(ePtr<iTimeshiftService> &ptr)
 {
        ptr = 0;
+       eDebug("[eDVBServicePlay::timeshift]");
        if (m_timeshift_enabled || !m_is_pvr)
        {
                if (!m_timeshift_enabled)
@@ -1758,7 +1759,7 @@ RESULT eDVBServicePlay::timeshift(ePtr<iTimeshiftService> &ptr)
                        std::string tspath = eConfigManager::getConfigValue("config.usage.timeshift_path");
                        if(tspath == "")
                        {
-                               eDebug("eDVBServicePlay::timeshift: could not query ts path from config");
+                               eDebug("[eDVBServicePlay::timeshift] could not query ts path from config");
                                return -4;
                        }
                        tspath.append("/");
@@ -1766,13 +1767,13 @@ RESULT eDVBServicePlay::timeshift(ePtr<iTimeshiftService> &ptr)
                        struct statfs fs;
                        if (statfs(tspath.c_str(), &fs) < 0)
                        {
-                               eDebug("eDVBServicePlay::timeshift: statfs failed!");
+                               eDebug("[eDVBServicePlay::timeshift] %s statfs failed!", tspath.c_str());
                                return -2;
                        }
 
                        if (((off_t)fs.f_bavail) * ((off_t)fs.f_bsize) < 200*1024*1024LL)
                        {
-                               eDebug("eDVBServicePlay::timeshift: not enough diskspace for timeshift! (less than 200MB)");
+                               eDebug("[eDVBServicePlay::timeshift] not enough diskspace for timeshift! (less than 200MB)");
                                return -3;
                        }
                }
@@ -2158,18 +2159,18 @@ int eDVBServicePlay::selectAudioStream(int i)
        }
 
        if (i != -1 && apid != m_current_audio_pid && (m_is_pvr || m_timeshift_active))
-               eDebug("eDVBServicePlay: getPlayPosition ret %d, pos %lld in selectAudioStream", getPlayPosition(position), position);
+               eDebug("[eDVBServicePlay] getPlayPosition ret %d, pos %lld in selectAudioStream", getPlayPosition(position), position);
 
        m_current_audio_pid = apid;
 
        if (m_decoder->setAudioPID(apid, apidtype))
        {
-               eDebug("eDVBServicePlay: set audio pid failed");
+               eDebug("[eDVBServicePlay] set audio pid failed");
                return -4;
        }
 
        if (position != -1)
-               eDebug("eDVBServicePlay: seekTo ret %d", seekTo(position));
+               eDebug("[eDVBServicePlay] seekTo ret %d", seekTo(position));
 
        int rdsPid = apid;
 
@@ -2276,13 +2277,13 @@ void eDVBServicePlay::showRassSlidePicture()
                        if (rass_slide_pic.length())
                                m_decoder->showSinglePic(rass_slide_pic.c_str());
                        else
-                               eDebug("eDVBServicePlay: empty filename for rass slide picture received!!");
+                               eDebug("[eDVBServicePlay] empty filename for rass slide picture received!!");
                }
                else
-                       eDebug("eDVBServicePlay: no MPEG Decoder to show iframes avail");
+                       eDebug("[eDVBServicePlay] no MPEG Decoder to show iframes avail");
        }
        else
-               eDebug("eDVBServicePlay: showRassSlidePicture called.. but not decoder");
+               eDebug("[eDVBServicePlay] showRassSlidePicture called.. but not decoder");
 }
 
 void eDVBServicePlay::showRassInteractivePic(int page, int subpage)
@@ -2295,13 +2296,13 @@ void eDVBServicePlay::showRassInteractivePic(int page, int subpage)
                        if (rass_interactive_pic.length())
                                m_decoder->showSinglePic(rass_interactive_pic.c_str());
                        else
-                               eDebug("eDVBServicePlay: empty filename for rass interactive picture %d/%d received!!", page, subpage);
+                               eDebug("[eDVBServicePlay] empty filename for rass interactive picture %d/%d received!!", page, subpage);
                }
                else
-                       eDebug("eDVBServicePlay: no MPEG Decoder to show iframes avail");
+                       eDebug("[eDVBServicePlay] no MPEG Decoder to show iframes avail");
        }
        else
-               eDebug("eDVBServicePlay: showRassInteractivePic called.. but not decoder");
+               eDebug("[eDVBServicePlay] showRassInteractivePic called.. but not decoder");
 }
 
 ePyObject eDVBServicePlay::getRassInteractiveMask()
@@ -2385,7 +2386,7 @@ RESULT eDVBServicePlay::startTimeshift()
 {
        ePtr<iDVBDemux> demux;
 
-       eDebug("eDVBServicePlay: Start timeshift!");
+       eDebug("[eDVBServicePlay] Start timeshift!");
 
        if (m_timeshift_enabled)
                return -1;
@@ -2401,12 +2402,12 @@ RESULT eDVBServicePlay::startTimeshift()
        std::string tspath = eConfigManager::getConfigValue("config.usage.timeshift_path");
        if (tspath == "")
        {
-               eDebug("eDVBServicePlay: could not query ts path");
+               eDebug("[eDVBServicePlay] could not query timeshift path");
                return -5;
        }
        if (tspath.empty())
        {
-               eDebug("eDVBServicePlay: TS path is empty");
+               eDebug("[eDVBServicePlay] timeshift path is empty");
                return -5;
        }
        if (tspath[tspath.length()-1] != '/')
@@ -2416,7 +2417,7 @@ RESULT eDVBServicePlay::startTimeshift()
        strcpy(templ, tspath.c_str());
        m_timeshift_fd = mkstemp(templ);
        m_timeshift_file = std::string(templ);
-       eDebug("eDVBServicePlay: recording to %s", templ);
+       eDebug("[eDVBServicePlay] timeshift recording to %s", templ);
        delete [] templ;
 
        if (m_timeshift_fd < 0)
@@ -2457,14 +2458,14 @@ RESULT eDVBServicePlay::stopTimeshift(bool swToLive)
 
        if (!m_save_timeshift)
        {
-               eDebug("eDVBServicePlay: remove timeshift files");
+               eDebug("[eDVBServicePlay] remove timeshift files");
                eBackgroundFileEraser::getInstance()->erase(m_timeshift_file);
                eBackgroundFileEraser::getInstance()->erase(m_timeshift_file + ".sc");
                eBackgroundFileEraser::getInstance()->erase(m_timeshift_file + ".cuts");
        }
        else
        {
-               eDebug("eDVBServicePlay: timeshift files not deleted");
+               eDebug("[eDVBServicePlay] timeshift files not deleted");
                m_save_timeshift = 0;
        }
        return 0;
@@ -2542,24 +2543,24 @@ void eDVBServicePlay::setCutList(ePyObject list)
                ePyObject tuple = PyList_GET_ITEM(list, i);
                if (!PyTuple_Check(tuple))
                {
-                       eDebug("eDVBServicePlay: non-tuple in cutlist");
+                       eDebug("[eDVBServicePlay] non-tuple in cutlist");
                        continue;
                }
                if (PyTuple_Size(tuple) != 2)
                {
-                       eDebug("eDVBServicePlay: cutlist entries need to be a 2-tuple");
+                       eDebug("[eDVBServicePlay] cutlist entries need to be a 2-tuple");
                        continue;
                }
                ePyObject ppts = PyTuple_GET_ITEM(tuple, 0), ptype = PyTuple_GET_ITEM(tuple, 1);
                if (!(PyLong_Check(ppts) && PyInt_Check(ptype)))
                {
-                       eDebug("eDVBServicePlay: cutlist entries need to be (pts, type)-tuples (%d %d)", PyLong_Check(ppts), PyInt_Check(ptype));
+                       eDebug("[eDVBServicePlay] cutlist entries need to be (pts, type)-tuples (%d %d)", PyLong_Check(ppts), PyInt_Check(ptype));
                        continue;
                }
                pts_t pts = PyLong_AsLongLong(ppts);
                int type = PyInt_AsLong(ptype);
                m_cue_entries.insert(cueEntry(pts, type));
-               eDebug("eDVBServicePlay: adding %08llx, %d", pts, type);
+               eDebug("[eDVBServicePlay] adding %08llx, %d", pts, type);
        }
        m_cuesheet_changed = 1;
 
@@ -2661,7 +2662,7 @@ void eDVBServicePlay::switchToLive()
        if (!m_timeshift_active)
                return;
 
-       eDebug("eDVBServicePlay: SwitchToLive");
+       eDebug("[eDVBServicePlay] SwitchToLive");
 
        resetTimeshift(0);
 
@@ -2736,7 +2737,7 @@ void eDVBServicePlay::switchToTimeshift()
        ePtr<iTsSource> source = createTsSource(r);
        m_service_handler_timeshift.tuneExt(r, 1, source, m_timeshift_file.c_str(), m_cue, 0, m_dvb_service, eDVBServicePMTHandler::timeshift_playback, false); /* use the decoder demux for everything */
 
-       eDebug("eDVBServicePlay: eDVBServicePlay::switchToTimeshift, in pause mode now.");
+       eDebug("[eDVBServicePlay] switchToTimeshift, in pause mode now.");
        pause();
        updateDecoder(true); /* mainly to switch off PCR, and to set pause */
 }
@@ -2750,10 +2751,10 @@ void eDVBServicePlay::updateDecoder(bool sendSeekableStateChanged)
 
        eDVBServicePMTHandler::program program;
        if (h.getProgramInfo(program))
-               eDebug("eDVBServicePlay: getting program info failed.");
+               eDebug("[eDVBServicePlay] getting program info failed.");
        else
        {
-               eDebugNoNewLineStart("eDVBServicePlay: have %zd video stream(s)", program.videoStreams.size());
+               eDebugNoNewLineStart("[eDVBServicePlay] have %zd video stream(s)", program.videoStreams.size());
                if (!program.videoStreams.empty())
                {
                        eDebugNoNewLine(" (");
@@ -2954,9 +2955,9 @@ void eDVBServicePlay::loadCuesheet()
                        m_cue_entries.insert(cueEntry(where, what));
                }
                fclose(f);
-               eDebug("eDVBServicePlay: cuts file has %zd entries", m_cue_entries.size());
+               eDebug("[eDVBServicePlay] cuts file has %zd entries", m_cue_entries.size());
        } else
-               eDebug("eDVBServicePlay: cutfile not found!");
+               eDebug("[eDVBServicePlay] cutfile not found!");
 
        m_cuesheet_changed = 0;
        cutlistToCuesheet();
@@ -2998,7 +2999,7 @@ void eDVBServicePlay::cutlistToCuesheet()
 {
        if (!m_cue)
        {
-               eDebug("eDVBServicePlay: no cue sheet");
+               eDebug("[eDVBServicePlay] no cue sheet");
                return;
        }
        m_cue->clear();
@@ -3006,7 +3007,7 @@ void eDVBServicePlay::cutlistToCuesheet()
        if ((m_cutlist_enabled & 1) == 0)
        {
                m_cue->commitSpans();
-               eDebug("eDVBServicePlay: cutlists were disabled");
+               eDebug("[eDVBServicePlay] cutlists were disabled");
                return;
        }
 
@@ -3075,7 +3076,7 @@ RESULT eDVBServicePlay::enableSubtitles(iSubtitleUser *user, SubtitleTrack &trac
 
                if (!m_teletext_parser)
                {
-                       eDebug("eDVBServicePlay: enable teletext subtitles.. no parser !!!");
+                       eDebug("[eDVBServicePlay] enable teletext subtitles.. no parser !!!");
                        return -1;
                }
 
@@ -3105,7 +3106,7 @@ RESULT eDVBServicePlay::enableSubtitles(iSubtitleUser *user, SubtitleTrack &trac
                int pid = 0, composition_page_id = 0, ancillary_page_id = 0;
                if (!m_subtitle_parser)
                {
-                       eDebug("eDVBServicePlay: enable dvb subtitles.. no parser !!!");
+                       eDebug("[eDVBServicePlay] enable dvb subtitles.. no parser !!!");
                        return -1;
                }
 
@@ -3122,7 +3123,7 @@ RESULT eDVBServicePlay::enableSubtitles(iSubtitleUser *user, SubtitleTrack &trac
                goto error_out;
        return 0;
 error_out:
-       eDebug("eDVBServicePlay: enableSubtitles needs a valid type:\n"
+       eDebug("[eDVBServicePlay] enableSubtitles needs a valid type:\n"
                "for teletext subtitles (0, pid, teletext_page, teletext_magazine)\n"
                "for dvb subtitles (1, pid, composition_page_id, ancillary_page_id)");
        return -1;
@@ -3216,7 +3217,7 @@ RESULT eDVBServicePlay::getSubtitleList(std::vector<SubtitleTrack> &subtitlelist
        eDVBServicePMTHandler &h = m_timeshift_active ? m_service_handler_timeshift : m_service_handler;
        eDVBServicePMTHandler::program program;
        if (h.getProgramInfo(program))
-               eDebug("eDVBServicePlay: getting program info failed.");
+               eDebug("[eDVBServicePlay] getting program info failed.");
        else
        {
                for (std::vector<eDVBServicePMTHandler::subtitleStream>::iterator it(program.subtitleStreams.begin());
@@ -3292,7 +3293,7 @@ void eDVBServicePlay::newSubtitlePage(const eDVBTeletextSubtitlePage &page)
                m_decoder->getPTS(0, pts);
                if (m_is_pvr || m_timeshift_enabled)
                {
-                       eDebug("eDVBServicePlay: Subtitle in recording/timeshift");
+                       eDebug("[eDVBServicePlay] Subtitle in recording/timeshift");
                        subtitledelay = eConfigManager::getConfigIntValue("config.subtitles.subtitle_noPTSrecordingdelay", 315000);
                }
                else
@@ -3301,7 +3302,7 @@ void eDVBServicePlay::newSubtitlePage(const eDVBTeletextSubtitlePage &page)
                        subtitledelay = eConfigManager::getConfigIntValue("config.subtitles.subtitle_bad_timing_delay", 0);
                }
 
-               // eDebug("eDVBServicePlay: Subtitle get  TTX have_pts=%d pvr=%d timeshift=%d page.pts=%lld pts=%lld delay=%d", page.m_have_pts, m_is_pvr, m_timeshift_enabled, page.m_pts, pts, subtitledelay);
+               // eDebug("[eDVBServicePlay] Subtitle get  TTX have_pts=%d pvr=%d timeshift=%d page.pts=%lld pts=%lld delay=%d", page.m_have_pts, m_is_pvr, m_timeshift_enabled, page.m_pts, pts, subtitledelay);
                eDVBTeletextSubtitlePage tmppage = page;
                tmppage.m_have_pts = true;
 
@@ -3318,7 +3319,7 @@ void eDVBServicePlay::newSubtitlePage(const eDVBTeletextSubtitlePage &page)
 void eDVBServicePlay::checkSubtitleTiming()
 {
        pts_t pos = 0;
-//     eDebug("eDVBServicePlay: checkSubtitleTiming");
+//     eDebug("[eDVBServicePlay] checkSubtitleTiming");
        if (!m_subtitle_widget)
                return;
        if (m_subtitle_pages.empty() && m_dvb_subtitle_pages.empty())
@@ -3352,7 +3353,7 @@ void eDVBServicePlay::checkSubtitleTiming()
                        return;
 
                int diff = show_time - pos;
-//             eDebug("eDVBServicePlay: Subtitle show %d page.pts=%lld pts=%lld diff=%d", type, show_time, pos, diff);
+//             eDebug("[eDVBServicePlay] Subtitle show %d page.pts=%lld pts=%lld diff=%d", type, show_time, pos, diff);
 
                if (diff < 20*90 || diff > 1800000)
                {
@@ -3383,7 +3384,7 @@ void eDVBServicePlay::newDVBSubtitlePage(const eDVBSubtitlePage &p)
                        m_decoder->getPTS(0, pos);
                if ( abs(pos-p.m_show_time)>1800000 && (m_is_pvr || m_timeshift_enabled))
                {
-                       eDebug("eDVBServicePlay: Subtitle without PTS and recording");
+                       eDebug("[eDVBServicePlay] Subtitle without PTS and recording");
                        int subtitledelay = eConfigManager::getConfigIntValue("config.subtitles.subtitle_noPTSrecordingdelay", 315000);
 
                        eDVBSubtitlePage tmppage;