summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/page')
-rw-r--r--core/fpdfapi/page/cpdf_iccprofile.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fpdfapi/page/cpdf_iccprofile.cpp b/core/fpdfapi/page/cpdf_iccprofile.cpp
index 94270b110b..0d6050790c 100644
--- a/core/fpdfapi/page/cpdf_iccprofile.cpp
+++ b/core/fpdfapi/page/cpdf_iccprofile.cpp
@@ -13,8 +13,8 @@
namespace {
bool DetectSRGB(pdfium::span<const uint8_t> span) {
- return span.size() == 3144 &&
- memcmp(span.data() + 0x190, "sRGB IEC61966-2.1", 17) == 0;
+ static const char kSRGB[] = "sRGB IEC61966-2.1";
+ return span.size() == 3144 && memcmp(&span[400], kSRGB, strlen(kSRGB)) == 0;
}
} // namespace