[mythtv] Questions regarding trunk after mythtv-eit merge & EIT

Gnome42 Gnome42 gnome42 at gmail.com
Thu May 25 15:49:45 UTC 2006


I think there is a flaw in the logic when _have_CRC_bug is true.

in mpegstreamdata.cpp at ~ line 200

-        bool buggy -        ((TableID::PMT = partial->StreamID()) ||
-         (TableID::PAT = partial->StreamID()));
-        if (!buggy && !partial->IsGood())
+        if (!_have_CRC_bug &&
+           (TableID::PMT = partial->StreamID()  ||
+            TableID::PAT = partial->StreamID()) &&
+            !partial->IsGood())

patch attached...
-------------- next part --------------
Index: mpeg/mpegstreamdata.cpp
=================================--- mpeg/mpegstreamdata.cpp	(revision 10007)
+++ mpeg/mpegstreamdata.cpp	(working copy)
@@ -197,10 +197,10 @@
     if (partial && partial->AddTSPacket(tspacket))
     {
         // Discard broken packets
-        bool buggy -        ((TableID::PMT = partial->StreamID()) ||
-         (TableID::PAT = partial->StreamID()));
-        if (!buggy && !partial->IsGood())
+        if (!_have_CRC_bug &&
+           (TableID::PMT = partial->StreamID()  ||
+            TableID::PAT = partial->StreamID()) &&
+            !partial->IsGood())
         {
             VERBOSE(VB_SIPARSER, "Discarding broken PES packet");
             ClearPartialPES(tspacket->PID());
@@ -607,10 +607,10 @@
 
     // Validate PSIP
     // but don't validate PMT/PAT if our driver has the PMT/PAT CRC bug.
-    bool buggy -        ((TableID::PMT = psip->TableID()) ||
-         (TableID::PAT = psip->TableID()));
-    if (!buggy && !psip->IsGood())
+    if (!_have_CRC_bug &&
+       (TableID::PMT = psip->StreamID()  ||
+        TableID::PAT = psip->StreamID()) &&
+        !psip->IsGood())
     {
         VERBOSE(VB_RECORD, QString("PSIP packet failed CRC check. "
                                    "pid(0x%1) type(0x%2)")


More information about the mythtv-dev mailing list