diff options
author | Jack Lloyd <[email protected]> | 2018-01-02 10:42:11 -0500 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2018-01-02 10:42:11 -0500 |
commit | 8326a481c1c7ae6ce18db8b4af9f413bd8435c3e (patch) | |
tree | 8210b7428915f3d485c260e6c679bd15a2082988 /src/lib/pubkey/ecies | |
parent | 0b957292b1c854a12356503d5b5c13e540101843 (diff) |
Cleanup ECIES test
And avoid warnings from Sonar about adding booleans
Diffstat (limited to 'src/lib/pubkey/ecies')
-rw-r--r-- | src/lib/pubkey/ecies/ecies.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/pubkey/ecies/ecies.cpp b/src/lib/pubkey/ecies/ecies.cpp index 39eb08afe..e2d574dcf 100644 --- a/src/lib/pubkey/ecies/ecies.cpp +++ b/src/lib/pubkey/ecies/ecies.cpp @@ -194,7 +194,7 @@ ECIES_System_Params::ECIES_System_Params(const EC_Group& domain, const std::stri m_mac_keylen(mac_key_len) { // ISO 18033: "At most one of CofactorMode, OldCofactorMode, and CheckMode may be 1." - if(cofactor_mode() + old_cofactor_mode() + check_mode() > 1) + if(size_t(cofactor_mode()) + size_t(old_cofactor_mode()) + size_t(check_mode()) > 1) { throw Invalid_Argument("ECIES: only one of cofactor_mode, old_cofactor_mode and check_mode can be set"); } |