summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenni Lund <kenni@mythtv.org>2011-04-13 19:04:11 (GMT)
committer Kenni Lund <kenni@mythtv.org>2011-04-13 19:04:11 (GMT)
commit43bef4efbe3214d3e4c7eb14d2098d0e38fd89e4 (patch)
treec1e86f0aaff653eaf74a528ef6859584456622b3
parente4f859a8dadbd62f50444318fbc8a7f4f4cc1098 (diff)
Filter out NULL-characters from EIT before we save the data in the database.
Refs #8707.
-rw-r--r--mythtv/libs/libmythtv/eitfixup.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/mythtv/libs/libmythtv/eitfixup.cpp b/mythtv/libs/libmythtv/eitfixup.cpp
index 9549c9a..5e55d75 100644
--- a/mythtv/libs/libmythtv/eitfixup.cpp
+++ b/mythtv/libs/libmythtv/eitfixup.cpp
@@ -186,11 +186,22 @@ void EITFixUp::Fix(DBEventEIT &event) const
if (event.fixup)
{
if (!event.title.isEmpty())
+ {
+ event.title = event.title.replace(QChar('\0'), "");
event.title = event.title.trimmed();
+ }
+
if (!event.subtitle.isEmpty())
+ {
+ event.subtitle = event.subtitle.replace(QChar('\0'), "");
event.subtitle = event.subtitle.trimmed();
+ }
+
if (!event.description.isEmpty())
+ {
+ event.description = event.description.replace(QChar('\0'), "");
event.description = event.description.trimmed();
+ }
}
if (kFixGenericDVB & event.fixup)