summary refs log tree commit diff
path: root/crypto
diff options
context:
space:
mode:
Diffstat (limited to 'crypto')
-rw-r--r--crypto/src/asn1/x500/Rdn.cs4
-rw-r--r--crypto/src/asn1/x500/style/IetfUtilities.cs11
2 files changed, 5 insertions, 10 deletions
diff --git a/crypto/src/asn1/x500/Rdn.cs b/crypto/src/asn1/x500/Rdn.cs
index 069a592a5..23537e1ae 100644
--- a/crypto/src/asn1/x500/Rdn.cs
+++ b/crypto/src/asn1/x500/Rdn.cs
@@ -2,9 +2,7 @@
 
 namespace Org.BouncyCastle.Asn1.X500
 {
-    /**
-     * Holding class for a single Relative Distinguished Name (RDN).
-     */
+    /// <summary>Holding class for a single Relative Distinguished Name (RDN).</summary>
     public class Rdn
         : Asn1Encodable
     {
diff --git a/crypto/src/asn1/x500/style/IetfUtilities.cs b/crypto/src/asn1/x500/style/IetfUtilities.cs
index acc1ed72e..dd2996bae 100644
--- a/crypto/src/asn1/x500/style/IetfUtilities.cs
+++ b/crypto/src/asn1/x500/style/IetfUtilities.cs
@@ -89,10 +89,9 @@ namespace Org.BouncyCastle.Asn1.X500.Style
 
             if (buf.Length > 0)
             {
-                int last = buf.Length - 1;
-                while (buf[last] == ' ' && lastEscaped != last)
+                while (buf[buf.Length - 1] == ' ' && lastEscaped != buf.Length - 1)
                 {
-                    buf.Length = last;
+                    buf.Length = buf.Length - 1;
                 }
             }
 
@@ -107,13 +106,11 @@ namespace Org.BouncyCastle.Asn1.X500.Style
         private static int ConvertHex(char c)
         {
             if ('0' <= c && c <= '9')
-            {
                 return c - '0';
-            }
+
             if ('a' <= c && c <= 'f')
-            {
                 return c - 'a' + 10;
-            }
+
             return c - 'A' + 10;
         }