Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1880)

Unified Diff: Source/modules/crypto/HmacKeyParams.cpp

Issue 23455017: Refactor how "length" parameter is obtained for HmacKeyParams. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | public/platform/WebCryptoAlgorithmParams.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/crypto/HmacKeyParams.cpp
diff --git a/Source/modules/crypto/HmacKeyParams.cpp b/Source/modules/crypto/HmacKeyParams.cpp
index 9e58ad45180b82ef285649eb2fdcc25d8fd1b2d4..1b918bdd0c6f3517f985a51ae148f9fd77091a4c 100644
--- a/Source/modules/crypto/HmacKeyParams.cpp
+++ b/Source/modules/crypto/HmacKeyParams.cpp
@@ -44,8 +44,9 @@ Algorithm* HmacKeyParams::hash()
unsigned HmacKeyParams::length(bool& isNull)
{
- isNull = !m_algorithm.hmacKeyParams()->hasLength();
- return isNull ? 0 : m_algorithm.hmacKeyParams()->length();
+ unsigned length;
+ isNull = !m_algorithm.hmacKeyParams()->getLength(length);
+ return length;
}
HmacKeyParams::HmacKeyParams(const WebKit::WebCryptoAlgorithm& algorithm)
« no previous file with comments | « no previous file | public/platform/WebCryptoAlgorithmParams.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698