mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
gofmt'ed more stragglers
(now down to a handfull of files in pkg) R=rsc http://go/go-review/1019006
This commit is contained in:
parent
f31bc223b3
commit
183edddb9d
2 changed files with 37 additions and 37 deletions
|
|
@ -110,15 +110,15 @@ type PrivateKey struct {
|
|||
|
||||
func (priv PrivateKey) Validate() os.Error {
|
||||
/*
|
||||
TODO(agl): Enable once big implements ProbablyPrime.
|
||||
TODO(agl): Enable once big implements ProbablyPrime.
|
||||
|
||||
// Check that p and q are prime.
|
||||
if !priv.P.ProbablyPrime(20) {
|
||||
return os.ErrorString("P is composite");
|
||||
}
|
||||
if !priv.Q.ProbablyPrime(20) {
|
||||
return os.ErrorString("Q is composite");
|
||||
}
|
||||
// Check that p and q are prime.
|
||||
if !priv.P.ProbablyPrime(20) {
|
||||
return os.ErrorString("P is composite");
|
||||
}
|
||||
if !priv.Q.ProbablyPrime(20) {
|
||||
return os.ErrorString("Q is composite");
|
||||
}
|
||||
*/
|
||||
// Check that p*q == n.
|
||||
modulus := new(big.Int).Mul(priv.P, priv.Q);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue