[libmath-prime-util-perl] 05/29: Must compare n and q as bigints

Partha P. Mukherjee ppm-guest at moszumanska.debian.org
Thu May 21 18:48:15 UTC 2015


This is an automated email from the git hooks/post-receive script.

ppm-guest pushed a commit to annotated tag v0.27
in repository libmath-prime-util-perl.

commit 8af5f6b02bbb8c523ef22b2e8eee9e6e086860c9
Author: Dana Jacobsen <dana at acm.org>
Date:   Tue Apr 30 00:37:52 2013 -0700

    Must compare n and q as bigints
---
 lib/Math/Prime/Util.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/Math/Prime/Util.pm b/lib/Math/Prime/Util.pm
index e5e77b2..d6e65df 100644
--- a/lib/Math/Prime/Util.pm
+++ b/lib/Math/Prime/Util.pm
@@ -1909,7 +1909,7 @@ sub verify_prime {
         warn "verify_prime: incorrect AGKM block format\n";
         return 0;
       }
-      if ($block->[0] != $q) {
+      if (Math::BigInt->new("$block->[0]") != Math::BigInt->new("$q")) {
         warn "verify_prime: incorrect AGKM block format: block n != q\n";
         return 0;
       }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmath-prime-util-perl.git



More information about the Pkg-perl-cvs-commits mailing list