label. (Reported by Alexei Bakharevski.)
int RAND_write_file(const char *file)
{
unsigned char buf[BUFSIZE];
- int i,ret=0,err=0;
+ int i,ret=0,rand_err=0;
FILE *out = NULL;
int n;
i=(n > BUFSIZE)?BUFSIZE:n;
n-=BUFSIZE;
if (RAND_bytes(buf,i) <= 0)
- err=1;
+ rand_err=1;
i=fwrite(buf,1,i,out);
if (i <= 0)
{
fclose(out);
memset(buf,0,BUFSIZE);
err:
- return(err ? -1 : ret);
+ return (rand_err ? -1 : ret);
}
const char *RAND_file_name(char *buf, int size)