aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil-cisco@xs4all.nl>2021-03-20 10:13:38 +0100
committerHans Verkuil <hverkuil-cisco@xs4all.nl>2021-03-20 10:13:38 +0100
commit4f5ba03dba8887062cf33267762ee1b4f3ea6159 (patch)
tree595b567cfa2e29cafaff6512be2e7e77cc6bdf5b
parent2bdd37f940d987e84b8091101e20f0218db21bdd (diff)
edid-decode: don't report bogus CTA-861 pref/native timings
If the CTA-861 block is absent, then edid-decode would still show the preferred and native timings 'if Block 0 and CTA-861 Blocks are parsed'. Fix this. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
-rw-r--r--parse-base-block.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/parse-base-block.cpp b/parse-base-block.cpp
index a2c12c5..5d6d77d 100644
--- a/parse-base-block.cpp
+++ b/parse-base-block.cpp
@@ -1049,8 +1049,10 @@ void edid_state::detailed_timings(const char *prefix, const unsigned char *x,
if (block_nr == 0 && base.dtd_cnt == 1) {
te.type = "DTD 1";
base.preferred_timing = te;
- cta.preferred_timings.push_back(te);
- cta.native_timings.push_back(te);
+ if (has_cta) {
+ cta.preferred_timings.push_back(te);
+ cta.native_timings.push_back(te);
+ }
}
if (base_or_cta)
cta.vec_dtds.push_back(te);

Privacy Policy