From 067a44fcad9196c6ad8cc3b2f86261b78ae54f48 Mon Sep 17 00:00:00 2001 From: Henrique Nakashima Date: Fri, 16 Feb 2018 03:46:28 +0000 Subject: Fix fallthroughs in XFA code. Change-Id: I1fd4bf85cd709de1c14ed2895d045018f79bc61f Reviewed-on: https://pdfium-review.googlesource.com/26950 Reviewed-by: dsinclair Commit-Queue: Henrique Nakashima --- core/fxcrt/css/cfx_csssyntaxparser.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core/fxcrt/css') diff --git a/core/fxcrt/css/cfx_csssyntaxparser.cpp b/core/fxcrt/css/cfx_csssyntaxparser.cpp index b557bf090b..30352a5a20 100644 --- a/core/fxcrt/css/cfx_csssyntaxparser.cpp +++ b/core/fxcrt/css/cfx_csssyntaxparser.cpp @@ -12,6 +12,7 @@ #include "core/fxcrt/css/cfx_cssdeclaration.h" #include "core/fxcrt/fx_codepage.h" #include "core/fxcrt/fx_extension.h" +#include "core/fxcrt/fx_fallthrough.h" #include "third_party/base/logging.h" namespace { @@ -73,6 +74,7 @@ CFX_CSSSyntaxStatus CFX_CSSSyntaxParser::DoSyntaxParse() { SwitchMode(CFX_CSSSyntaxMode::Comment); break; } + FX_FALLTHROUGH; default: if (wch <= ' ') { m_TextPlane.MoveNext(); @@ -109,6 +111,7 @@ CFX_CSSSyntaxStatus CFX_CSSSyntaxParser::DoSyntaxParse() { return CFX_CSSSyntaxStatus::Selector; break; } + FX_FALLTHROUGH; default: AppendChar(wch); break; @@ -133,6 +136,7 @@ CFX_CSSSyntaxStatus CFX_CSSSyntaxParser::DoSyntaxParse() { return CFX_CSSSyntaxStatus::PropertyName; break; } + FX_FALLTHROUGH; default: AppendChar(wch); break; @@ -142,6 +146,7 @@ CFX_CSSSyntaxStatus CFX_CSSSyntaxParser::DoSyntaxParse() { switch (wch) { case ';': m_TextPlane.MoveNext(); + FX_FALLTHROUGH; case '}': SwitchMode(CFX_CSSSyntaxMode::PropertyName); return CFX_CSSSyntaxStatus::PropertyValue; @@ -151,6 +156,7 @@ CFX_CSSSyntaxStatus CFX_CSSSyntaxParser::DoSyntaxParse() { return CFX_CSSSyntaxStatus::PropertyValue; break; } + FX_FALLTHROUGH; default: AppendChar(wch); break; -- cgit v1.2.3