Ticket #10871: diff-dump.txt

File diff-dump.txt, 2.0 KB (added by blm-ubunet@…, 7 years ago)

patch fix incorrect use of offset in recordedmarkup

Line 
1diff --git a/mythplugins/mytharchive/mytharchivehelper/main.cpp b/mythplugins/mytharchive/mytharchivehelper/main.cpp
2index 8189c06..745a3e6 100644
3--- a/mythplugins/mytharchive/mytharchivehelper/main.cpp
4+++ b/mythplugins/mytharchive/mytharchivehelper/main.cpp
5@@ -774,7 +774,7 @@ int NativeArchive::exportRecording(QDomElement   &itemNode,
6 
7     // add the recordedmarkup table
8     QDomElement recordedmarkup = doc.createElement("recordedmarkup");
9-    query.prepare("SELECT chanid, starttime, mark, offset, type "
10+    query.prepare("SELECT chanid, starttime, mark, data, type "
11             "FROM recordedmarkup "
12             "WHERE chanid = :CHANID and starttime = :STARTTIME;");
13     query.bindValue(":CHANID", chanID);
14@@ -785,7 +785,7 @@ int NativeArchive::exportRecording(QDomElement   &itemNode,
15         {
16             QDomElement mark = doc.createElement("mark");
17             mark.setAttribute("mark", query.value(2).toString());
18-            mark.setAttribute("offset", query.value(3).toString());
19+            mark.setAttribute("data", query.value(3).toString());
20             mark.setAttribute("type", query.value(4).toString());
21             recordedmarkup.appendChild(mark);
22         }
23@@ -1321,12 +1321,12 @@ int NativeArchive::importRecording(const QDomElement &itemNode,
24                 n = nodeList.item(x);
25                 QDomElement e = n.toElement();
26                 query.prepare("INSERT INTO recordedmarkup (chanid, starttime, "
27-                        "mark, offset, type)"
28-                        "VALUES(:CHANID,:STARTTIME,:MARK,:OFFSET,:TYPE);");
29+                        "mark, data, type)"
30+                        "VALUES(:CHANID,:STARTTIME,:MARK,:DATA,:TYPE);");
31                 query.bindValue(":CHANID", chanID);
32                 query.bindValue(":STARTTIME", startTime);
33                 query.bindValue(":MARK", e.attribute("mark"));
34-                query.bindValue(":OFFSET", e.attribute("offset"));
35+                query.bindValue(":DATA", e.attribute("data"));
36                 query.bindValue(":TYPE", e.attribute("type"));
37 
38