diff --git a/lib/dvb/db.cpp b/lib/dvb/db.cpp index 71562618c1..28bef408f0 100644 --- a/lib/dvb/db.cpp +++ b/lib/dvb/db.cpp @@ -21,6 +21,7 @@ #include #include #include +#include /* * Copyright (C) 2017 Marcus Metzler @@ -2677,7 +2678,7 @@ RESULT eDVBDB::removeBouquet(const std::string &filename) if (entry->d_type == DT_REG) { std::string path = entry->d_name; - if (path.find(filename) != std::string::npos) + if (std::regex_search(path, std::regex("^" + filename + "$"))) { std::string bouquetquery = "FROM BOUQUET \"" + path + "\" ORDER BY bouquet"; eServiceReference bouquetref(eServiceReference::idDVB, eServiceReference::flagDirectory, bouquetquery);