summaryrefslogtreecommitdiff
path: root/core/fpdfapi
diff options
context:
space:
mode:
authortsepez <tsepez@chromium.org>2016-04-08 12:13:50 -0700
committerCommit bot <commit-bot@chromium.org>2016-04-08 12:13:50 -0700
commitf172290a8dc527cd8bc73b0d0ad59e78797968c1 (patch)
tree7e04b3e6d025ba1d2683da1ae668b0505d9cfe98 /core/fpdfapi
parent8b36e5cc3d5f5f579c6b060e2c40b896a4b02bc0 (diff)
downloadpdfium-f172290a8dc527cd8bc73b0d0ad59e78797968c1.tar.xz
Remove CFX_ByteString::Load() and operator= for CFX_ByteTextBuf
The few places these are called are better served by explicit calls to CFX_ByteString() itself. This helps make Byte and Wide strings more similar. Also prevents fx_string.h from having any knowledge of fx_basic.h's ByteTextBuf class. Review URL: https://codereview.chromium.org/1870043003
Diffstat (limited to 'core/fpdfapi')
-rw-r--r--core/fpdfapi/fpdf_parser/cpdf_standard_crypto_handler.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fpdfapi/fpdf_parser/cpdf_standard_crypto_handler.cpp b/core/fpdfapi/fpdf_parser/cpdf_standard_crypto_handler.cpp
index 46384244e8..6bfe1b60b3 100644
--- a/core/fpdfapi/fpdf_parser/cpdf_standard_crypto_handler.cpp
+++ b/core/fpdfapi/fpdf_parser/cpdf_standard_crypto_handler.cpp
@@ -20,9 +20,9 @@ void IPDF_CryptoHandler::Decrypt(uint32_t objnum,
CFX_ByteString& str) {
CFX_BinaryBuf dest_buf;
void* context = DecryptStart(objnum, gennum);
- DecryptStream(context, (const uint8_t*)str, str.GetLength(), dest_buf);
+ DecryptStream(context, str.raw_str(), str.GetLength(), dest_buf);
DecryptFinish(context, dest_buf);
- str = dest_buf;
+ str = CFX_ByteString(dest_buf.GetBuffer(), dest_buf.GetSize());
}
void CPDF_StandardCryptoHandler::CryptBlock(FX_BOOL bEncrypt,