From 655c783b8077f18e17418a3aab9b5a07c8055049 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Tue, 23 May 2017 17:10:46 -0700 Subject: Convert to CFX_UnownedPtr, part 3. Remove an explicit clear to re-order the member destruction order. Change-Id: I33da3f3de4b8e8e0cfbdceaf5140e98f5d6f904a Reviewed-on: https://pdfium-review.googlesource.com/5791 Reviewed-by: Lei Zhang Commit-Queue: Tom Sepez --- core/fpdfapi/parser/cpdf_security_handler.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'core/fpdfapi/parser/cpdf_security_handler.cpp') diff --git a/core/fpdfapi/parser/cpdf_security_handler.cpp b/core/fpdfapi/parser/cpdf_security_handler.cpp index 85a3805eea..4cdf545d63 100644 --- a/core/fpdfapi/parser/cpdf_security_handler.cpp +++ b/core/fpdfapi/parser/cpdf_security_handler.cpp @@ -413,7 +413,7 @@ bool CPDF_SecurityHandler::CheckUserPassword(const uint8_t* password, bool bIgnoreEncryptMeta, uint8_t* key, int32_t key_len) { - CalcEncryptKey(m_pEncryptDict, password, pass_size, key, key_len, + CalcEncryptKey(m_pEncryptDict.Get(), password, pass_size, key, key_len, bIgnoreEncryptMeta, m_pParser->GetIDArray()); CFX_ByteString ukey = m_pEncryptDict ? m_pEncryptDict->GetStringFor("U") : CFX_ByteString(); @@ -578,8 +578,8 @@ void CPDF_SecurityHandler::OnCreate(CPDF_Dictionary* pEncryptDict, pEncryptDict->SetNewFor("O", CFX_ByteString(passcode, 32), false); } - CalcEncryptKey(m_pEncryptDict, (uint8_t*)user_pass, user_size, m_EncryptKey, - key_len, false, pIdArray); + CalcEncryptKey(m_pEncryptDict.Get(), (uint8_t*)user_pass, user_size, + m_EncryptKey, key_len, false, pIdArray); if (m_Revision < 3) { uint8_t tempbuf[32]; memcpy(tempbuf, defpasscode, 32); -- cgit v1.2.3