From 3630243d8db023b4e1de14bfe86c454fda440ad9 Mon Sep 17 00:00:00 2001 From: Leonetienne Date: Wed, 25 May 2022 14:57:40 +0200 Subject: [PATCH] Fix macos compile issue --- GCryptLib/include/GCrypt/GPrng.h | 2 +- GCryptLib/src/Block.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/GCryptLib/include/GCrypt/GPrng.h b/GCryptLib/include/GCrypt/GPrng.h index 99e9a6a..b037a53 100644 --- a/GCryptLib/include/GCrypt/GPrng.h +++ b/GCryptLib/include/GCrypt/GPrng.h @@ -32,7 +32,7 @@ namespace Leonetienne::GCrypt { // Pull the required amount of bits std::stringstream ss; for (std::size_t i = 0; i < sizeof(T)*8; i++) { - ss << GetBit() ? '1' : '0'; + ss << (GetBit() ? '1' : '0'); } // Transform to bytes diff --git a/GCryptLib/src/Block.cpp b/GCryptLib/src/Block.cpp index ac5a648..a9b2a23 100644 --- a/GCryptLib/src/Block.cpp +++ b/GCryptLib/src/Block.cpp @@ -532,7 +532,7 @@ namespace Leonetienne::GCrypt { std::ostream& operator<<(std::ostream& os, const Block& b) { for (std::size_t i = 0; i < b.data.size(); i++) { - os << std::bitset(b.data[i]).to_string(); + os << std::bitset(b.data[i]).to_string(); } return os; }