fixes for small typos in random-fips.c

Patrick Pelletier code at funwithsoftware.org
Wed Dec 28 11:50:22 CET 2011


Hi,

I just saw a few typos in random-fips.c and wanted to submit 
corrections.  Is this the right place and format for doing so?  I've 
pasted a diff below, which hopefully won't get badly mangled by my email 
client.

Thanks,

--Patrick


diff --git a/random/random-fips.c b/random/random-fips.c
index e0ae968..f45f370 100644
--- a/random/random-fips.c
+++ b/random/random-fips.c
@@ -104,7 +104,7 @@ static size_t entropy_collect_buffer_size;

  /* This random context type is used to track properties of one random
     generator. Thee context are usually allocated in secure memory so
-   that the seed value is well protected.  There are a couble of guard
+   that the seed value is well protected.  There are a couple of guard
     fields to help detecting applications accidently overwriting parts
     of the memory. */
  struct rng_context
@@ -141,10 +141,10 @@ struct rng_context

    unsigned char guard_3[1];

-  /* The external test may want to suppress the duplicate bock check.
+  /* The external test may want to suppress the duplicate block check.
       This is done if the this flag is set.  */
    unsigned char test_no_dup_check;
-  /* To implement a KAT we need to provide a know DT value.  To
+  /* To implement a KAT we need to provide a known DT value.  To
       accomplish this the x931_get_dt function checks whether this
       field is not NULL and then uses the 16 bytes at this address for
       the DT value.  However the last 4 bytes are replaced by the
@@ -308,7 +308,7 @@ x931_get_dt (unsigned char *buffer, size_t length,
      if (!last_sec)
        {
          /* This is the very first time we are called: Set the counters
-           to an not so easy predictable value to avoid always
+           to a not so easily predictable value to avoid always
             starting at 0.  Not really needed but it doesn't harm.  */
          counter1 = (u32)getpid ();
  #ifndef HAVE_W32_SYSTEM
@@ -468,7 +468,7 @@ x931_aes_driver (unsigned char *output, size_t

        /* Due to the design of the RNG, we always receive 16 bytes (128
           bit) of random even if we require less.  The extra bytes
-         returned are not used.  Intheory we could save them for the
+         returned are not used.  In theory we could save them for the
           next invocation, but that would make the control flow harder
           to read.  */
        nbytes = length < 16? length : 16;



More information about the Gcrypt-devel mailing list