Thread (31 messages) 31 messages, 2 authors, 2021-09-27

Re: [PATCH v2 05/29] edid-decode: Capitalize fail sentence

From: Hans Verkuil <hidden>
Date: 2021-09-27 07:55:48

On 26/09/2021 10:33, joevt wrote:
- Most fail messages are a sentence that starts with a capital letter and ends with a period.
- Remove unnessary break from last switch case.
I dropped this change. It is good coding practice to always include a break for the last switch case.
If someone adds a new case later, then this avoids an accidental fall-through scenario.

No need to repost, I'll take care of this.

Regards,

	Hans
quoted hunk ↗ jump to hunk
- Remove extra line.

Signed-off-by: Joe van Tunen <redacted>
---
 parse-cta-block.cpp | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/parse-cta-block.cpp b/parse-cta-block.cpp
index 6607426..042b933 100644
--- a/parse-cta-block.cpp
+++ b/parse-cta-block.cpp
@@ -2091,13 +2091,11 @@ void edid_state::cta_ext_block(const unsigned char *x, unsigned length,
 	case 0x79:
 		if (duplicate)
 			fail("Only one instance of this Data Block is allowed.\n");
-		break;
 	}
 
-
 	// See Table 52 of CTA-861-G for a description of Byte 3
 	if (audio_block && !(cta.byte3 & 0x40))
-		fail("audio information is present, but bit 6 of Byte 3 of the CTA-861 Extension header indicates no Basic Audio support.\n");
+		fail("Audio information is present, but bit 6 of Byte 3 of the CTA-861 Extension header indicates no Basic Audio support.\n");
 
 	if (data_block.length())
 		printf("  %s:\n", data_block.c_str());
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help