Write random seed file in binary mode.
authorUlf Möller <ulf@openssl.org>
Fri, 16 Apr 1999 11:16:00 +0000 (11:16 +0000)
committerUlf Möller <ulf@openssl.org>
Fri, 16 Apr 1999 11:16:00 +0000 (11:16 +0000)
Submitted by: Richard Levitte <levitte@stacken.kth.se>

crypto/rand/randfile.c

index 3ae95f9..c874431 100644 (file)
@@ -116,7 +116,7 @@ const char *file;
        FILE *out;
        int n;
 
        FILE *out;
        int n;
 
-       out=fopen(file,"w");
+       out=fopen(file,"wb");
        if (out == NULL) goto err;
        chmod(file,0600);
        n=RAND_DATA;
        if (out == NULL) goto err;
        chmod(file,0600);
        n=RAND_DATA;