diff options
author | Underground78 <underground78@users.sourceforge.net> | 2013-05-02 21:12:44 +0400 |
---|---|---|
committer | Underground78 <underground78@users.sourceforge.net> | 2013-05-03 00:24:17 +0400 |
commit | 0c6d8f7cd0eff4d2495c0932a9e0cee15adff6a0 (patch) | |
tree | 26cacd9311acf44d2405245409ce5033e47e5b10 | |
parent | e72ec04d31d197e01ea52d16b85dec40b7cdef34 (diff) |
DVB: Improve the compatibility with some drivers after ada3ea6714e7c5f11e73df27aa7123c5a491e362.
MPC-HC failed to find any channel for some drivers.
We now try to get the statistics information from any interface available even if it's not the non-preferred one to be more fool-proof.
This commit fixes #3110.
-rw-r--r-- | docs/Changelog.txt | 2 | ||||
-rw-r--r-- | src/mpc-hc/FGManagerBDA.cpp | 16 |
2 files changed, 14 insertions, 4 deletions
diff --git a/docs/Changelog.txt b/docs/Changelog.txt index cd7164aab..d463e6f15 100644 --- a/docs/Changelog.txt +++ b/docs/Changelog.txt @@ -20,6 +20,8 @@ Legend: of 4 by default instead of 10
! PGS and DVB subtitles: Fix missing subtitles after resizing the window when using
the subpicture queue.
+! Ticket #3110, DVB: Improve the compatibility with some drivers for which MPC-HC failed to find
+ any channel during the scan
1.6.7 - 25 April 2013
diff --git a/src/mpc-hc/FGManagerBDA.cpp b/src/mpc-hc/FGManagerBDA.cpp index 1b5b9ca59..29f1a0042 100644 --- a/src/mpc-hc/FGManagerBDA.cpp +++ b/src/mpc-hc/FGManagerBDA.cpp @@ -617,10 +617,18 @@ STDMETHODIMP CFGManagerBDA::GetStats(BOOLEAN& bPresent, BOOLEAN& bLocked, LONG& CheckPointer(m_pBDATunerStats, E_UNEXPECTED);
CheckPointer(m_pBDADemodStats, E_UNEXPECTED);
- CheckNoLog(m_pBDATunerStats->get_SignalPresent(&bPresent));
- CheckNoLog(m_pBDADemodStats->get_SignalLocked(&bLocked));
- CheckNoLog(m_pBDATunerStats->get_SignalStrength(&lDbStrength));
- CheckNoLog(m_pBDADemodStats->get_SignalQuality(&lPercentQuality));
+ if (FAILED(hr = m_pBDATunerStats->get_SignalPresent(&bPresent)) && FAILED(hr = m_pBDADemodStats->get_SignalPresent(&bPresent))) {
+ return hr;
+ }
+ if (FAILED(hr = m_pBDADemodStats->get_SignalLocked(&bLocked)) && FAILED(hr = m_pBDATunerStats->get_SignalLocked(&bLocked))) {
+ return hr;
+ }
+ if (FAILED(hr = m_pBDATunerStats->get_SignalStrength(&lDbStrength)) && FAILED(hr = m_pBDADemodStats->get_SignalStrength(&lDbStrength))) {
+ return hr;
+ }
+ if (FAILED(hr = m_pBDADemodStats->get_SignalQuality(&lPercentQuality)) && FAILED(hr = m_pBDATunerStats->get_SignalQuality(&lPercentQuality))) {
+ return hr;
+ }
LOG(_T("Get signal stats: Strength %d dB, Quality %d%%"), lDbStrength, lPercentQuality);
return S_OK;
|