LibCrypto: Make PEMType
an enum class
This is required for the following commits to avoid a conflict with the `Certificate` namespace.
This commit is contained in:
parent
03b9e555c0
commit
07ced0cb34
Notes:
github-actions[bot]
2024-11-25 13:12:35 +00:00
Author: https://github.com/devgianlu Commit: https://github.com/LadybirdBrowser/ladybird/commit/07ced0cb340 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2563 Reviewed-by: https://github.com/alimpfard ✅
2 changed files with 3 additions and 3 deletions
|
@ -100,11 +100,11 @@ ErrorOr<ByteBuffer> encode_pem(ReadonlyBytes data, PEMType type)
|
|||
StringView block_end;
|
||||
|
||||
switch (type) {
|
||||
case Certificate:
|
||||
case PEMType::Certificate:
|
||||
block_start = "-----BEGIN CERTIFICATE-----\n"sv;
|
||||
block_end = "-----END CERTIFICATE-----\n"sv;
|
||||
break;
|
||||
case PrivateKey:
|
||||
case PEMType::PrivateKey:
|
||||
block_start = "-----BEGIN PRIVATE KEY-----\n"sv;
|
||||
block_end = "-----END PRIVATE KEY-----\n"sv;
|
||||
break;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Crypto {
|
||||
|
||||
enum PEMType {
|
||||
enum class PEMType {
|
||||
Certificate,
|
||||
PrivateKey,
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue