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

Side by Side Diff: third_party/WebKit/Source/platform/Crypto.cpp

Issue 2700123003: DO NOT COMMIT: Results of running old (current) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "platform/Crypto.h" 5 #include "platform/Crypto.h"
6 6
7 #include <memory>
7 #include "public/platform/Platform.h" 8 #include "public/platform/Platform.h"
8 #include "public/platform/WebCrypto.h" 9 #include "public/platform/WebCrypto.h"
9 #include "public/platform/WebCryptoAlgorithm.h" 10 #include "public/platform/WebCryptoAlgorithm.h"
10 #include <memory>
11 11
12 namespace blink { 12 namespace blink {
13 13
14 static WebCryptoAlgorithmId toWebCryptoAlgorithmId(HashAlgorithm algorithm) { 14 static WebCryptoAlgorithmId toWebCryptoAlgorithmId(HashAlgorithm algorithm) {
15 switch (algorithm) { 15 switch (algorithm) {
16 case HashAlgorithmSha1: 16 case HashAlgorithmSha1:
17 return WebCryptoAlgorithmIdSha1; 17 return WebCryptoAlgorithmIdSha1;
18 case HashAlgorithmSha256: 18 case HashAlgorithmSha256:
19 return WebCryptoAlgorithmIdSha256; 19 return WebCryptoAlgorithmIdSha256;
20 case HashAlgorithmSha384: 20 case HashAlgorithmSha384:
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 61
62 if (!digestor->finish(result, resultSize)) 62 if (!digestor->finish(result, resultSize))
63 return; 63 return;
64 64
65 ASSERT(result); 65 ASSERT(result);
66 66
67 digestResult.append(static_cast<uint8_t*>(result), resultSize); 67 digestResult.append(static_cast<uint8_t*>(result), resultSize);
68 } 68 }
69 69
70 } // namespace blink 70 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/Crypto.h ('k') | third_party/WebKit/Source/platform/DateComponents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698