From 89fa5dfee5107736597682f174fdc95d0baec830 Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Thu, 11 Jan 2018 14:15:03 +0000 Subject: Use range-based for-loops in a few more places. Change-Id: Id403abaf3d142dc30a661bc64ff48dbd5b10948e Reviewed-on: https://pdfium-review.googlesource.com/22736 Commit-Queue: dsinclair Reviewed-by: dsinclair --- fpdfsdk/pwl/cpwl_font_map.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'fpdfsdk/pwl') diff --git a/fpdfsdk/pwl/cpwl_font_map.cpp b/fpdfsdk/pwl/cpwl_font_map.cpp index 4a2ac4bcb8..5e5556ebb0 100644 --- a/fpdfsdk/pwl/cpwl_font_map.cpp +++ b/fpdfsdk/pwl/cpwl_font_map.cpp @@ -149,8 +149,8 @@ void CPWL_FontMap::Initialize() { } bool CPWL_FontMap::IsStandardFont(const ByteString& sFontName) { - for (size_t i = 0; i < FX_ArraySize(g_sDEStandardFontName); ++i) { - if (sFontName == g_sDEStandardFontName[i]) + for (const char* name : g_sDEStandardFontName) { + if (sFontName == name) return true; } -- cgit v1.2.3