Opened 11 years ago

Closed 11 years ago

Last modified 10 years ago

#11298 closed Bug Report - General (fixed)

Changeset be8dd3067b broke working of DVB-C cam module

Reported by: gemma.daan@… Owned by: danielk
Priority: minor Milestone: 0.27
Component: MythTV - DVB Version: Master Head
Severity: high Keywords:
Cc: Ticket locked: no

Description

In changeset be8dd3067b some "dead code" was commented out, unfortunately, this is not really dead code, as the "Tc->Poll()" method also makes sure the CAM module is working.

This changeset causes that encrypted channels can't be recorded any more.

            case stACTIVE:
                 if (!Tc->DataAvailable()) {
-                   if (Tc->Poll() != OK)
-                      ;//XXX continue;
+//                   if (Tc->Poll() != OK)
+//                      ;//XXX continue;
                    }
                 switch (Tc->LastResponse()) {

I reverted this change in my local test tree and tested it on my test machine, it restored the working of the CAM module.

Attachments (1)

dvbci.cpp.patch (673 bytes) - added by klaas.de.waal@… 11 years ago.
Call Tc->Poll() outside if statement and ignore function value.

Download all attachments as: .zip

Change History (9)

comment:1 Changed 11 years ago by Daniel Kristjansson <danielk@…>

Resolution: fixed
Status: newclosed

In 40ff97370a7d7ad115c1f700131ff5464c34a484/mythtv:

Fixes #11298. Revert "Comment out dead code in dvbci.cpp to quiet clang++"

This code isn't as dead as I thought...

This reverts commit be8dd3067bdffcac651f5d00855105cbdfbe560f.

comment:2 Changed 11 years ago by Daniel Kristjansson <danielk@…>

In a7e8f7f363939864ed4b1c971f807b8c24aa324d/mythtv:

Refs #11298. Print error message on Poll error.

comment:3 Changed 11 years ago by Raymond Wagner

Milestone: unknown0.27

comment:4 Changed 11 years ago by klaas.de.waal@…

The error message added recently results in an endless stream of "E ERROR: Poll Error" messages, about 10 per second, in my otherwise correctly working system. The reason for this is that the "Tc->Poll()" method can also returns a value " != OK " when there is nothing wrong.
The way I understand it is that the function must be called and that the function value should be ignored. This is the way the code has been working in the last few years. Apparently the reason to change the code has been to remove compiler warnings. I think that to achieve this the function must not be called inside the "if" statement.
I will attach a trivial patch for this.

Changed 11 years ago by klaas.de.waal@…

Attachment: dvbci.cpp.patch added

Call Tc->Poll() outside if statement and ignore function value.

comment:5 Changed 11 years ago by klaas.de.waal@…

Resolution: fixed
Status: closednew

comment:6 Changed 11 years ago by Klass De Waal <klaas.de.waal@…>

Resolution: fixed
Status: newclosed

In 848e405d6c10ec9dcec360bb92b3485a2504129f/mythtv:

Call Tc->Poll() outside if statement and ignore function value.

Fixes #11298

Signed-off-by: Stuart Morgan <smorgan@…>
(cherry picked from commit 7c46e2ad254811c9210698f616e000aca749b035)

comment:7 Changed 11 years ago by Klass De Waal <klaas.de.waal@…>

In faffb0f22be12c0405852f5ddccfa64b6f128049/mythtv:

Call Tc->Poll() outside if statement and ignore function value.

Fixes #11298

Signed-off-by: Stuart Morgan <smorgan@…>

comment:8 Changed 10 years ago by crazy.bombz@…

Has this been fixed yet? My CAM is not working with 0.27 but worked fine as soon as I reverted to 0.26.

Note: See TracTickets for help on using tickets.