From d3706175d560ed8fbf3f4d3961cae910be1c77e0 Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Fri, 24 May 2019 07:06:07 -0400 Subject: Add script for running TLS fuzzer Fix a few minor issues found thereby --- src/lib/math/numbertheory/pow_mod.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/lib/math') diff --git a/src/lib/math/numbertheory/pow_mod.cpp b/src/lib/math/numbertheory/pow_mod.cpp index 00917a5f9..02434fe68 100644 --- a/src/lib/math/numbertheory/pow_mod.cpp +++ b/src/lib/math/numbertheory/pow_mod.cpp @@ -65,8 +65,8 @@ void Power_Mod::set_modulus(const BigInt& n, Usage_Hints hints, bool disable_mon */ void Power_Mod::set_base(const BigInt& b) const { - if(b.is_zero() || b.is_negative()) - throw Invalid_Argument("Power_Mod::set_base: arg must be > 0"); + if(b.is_negative()) + throw Invalid_Argument("Power_Mod::set_base: arg must be non-negative"); if(!m_core) throw Internal_Error("Power_Mod::set_base: m_core was NULL"); -- cgit v1.2.3