summary refs log tree commit diff
path: root/crypto/src
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src')
-rw-r--r--crypto/src/pkix/PkixCertPathValidatorResult.cs20
1 files changed, 7 insertions, 13 deletions
diff --git a/crypto/src/pkix/PkixCertPathValidatorResult.cs b/crypto/src/pkix/PkixCertPathValidatorResult.cs

index 693ded89c..07cb350c1 100644 --- a/crypto/src/pkix/PkixCertPathValidatorResult.cs +++ b/crypto/src/pkix/PkixCertPathValidatorResult.cs
@@ -31,20 +31,14 @@ namespace Org.BouncyCastle.Pkix get { return this.subjectPublicKey; } } - public PkixCertPathValidatorResult( - TrustAnchor trustAnchor, - PkixPolicyNode policyTree, - AsymmetricKeyParameter subjectPublicKey) + public PkixCertPathValidatorResult(TrustAnchor trustAnchor, PkixPolicyNode policyTree, + AsymmetricKeyParameter subjectPublicKey) { - if (subjectPublicKey == null) - { - throw new NullReferenceException("subjectPublicKey must be non-null"); - } - if (trustAnchor == null) - { - throw new NullReferenceException("trustAnchor must be non-null"); - } - + if (trustAnchor == null) + throw new ArgumentNullException(nameof(trustAnchor)); + if (subjectPublicKey == null) + throw new ArgumentNullException(nameof(subjectPublicKey)); + this.trustAnchor = trustAnchor; this.policyTree = policyTree; this.subjectPublicKey = subjectPublicKey;