diff options
author | Tom Sepez <tsepez@chromium.org> | 2018-04-12 19:45:45 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-04-12 19:45:45 +0000 |
commit | 80a6cbe0a427e155de8555bc867af745d10f9777 (patch) | |
tree | f5a01546d4081a4c3618350f4b54d13690d30299 /fpdfsdk | |
parent | 154e18f9a862975abecebe77b8f5fb418418d14c (diff) | |
download | pdfium-80a6cbe0a427e155de8555bc867af745d10f9777.tar.xz |
Return pdfium::span<char> from ByteString::GetBuffer().
Get bounds checking "for free".
Change-Id: I7b14cacbc7130ced7b5cb1869b82c96ccff8e642
Reviewed-on: https://pdfium-review.googlesource.com/30451
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk')
-rw-r--r-- | fpdfsdk/cpdfsdk_formfillenvironment.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fpdfsdk/cpdfsdk_formfillenvironment.cpp b/fpdfsdk/cpdfsdk_formfillenvironment.cpp index c1846449cd..262a56e2d1 100644 --- a/fpdfsdk/cpdfsdk_formfillenvironment.cpp +++ b/fpdfsdk/cpdfsdk_formfillenvironment.cpp @@ -25,7 +25,7 @@ FPDF_WIDESTRING AsFPDFWideString(ByteString* bsUTF16LE) { // to the embedder. Should the embedder modify it by accident, it won't // corrupt other shares of the string beyond |bsUTF16LE|. return reinterpret_cast<FPDF_WIDESTRING>( - bsUTF16LE->GetBuffer(bsUTF16LE->GetLength())); + bsUTF16LE->GetBuffer(bsUTF16LE->GetLength()).data()); } CPDFSDK_FormFillEnvironment::CPDFSDK_FormFillEnvironment( |