Browse Source

Removed duplicate check in random_seed test - bug #140

tags/json-c-0.13-20171207
Alexandru Costache alexandru.costache 11 years ago
parent
commit
4841c48f81
1 changed files with 2 additions and 5 deletions
  1. +2
    -5
      random_seed.c

+ 2
- 5
random_seed.c View File

@@ -160,13 +160,10 @@ static int get_dev_random_seed()
int r;
ssize_t nread = read(fd, &r, sizeof(r));
if (nread != sizeof(r)) {
fprintf(stderr, "error read %s: %s", dev_random_file, strerror(errno));
exit(1);
}
else if (nread != sizeof(r)) {
fprintf(stderr, "error short read %s", dev_random_file);
fprintf(stderr, "error short read %s: %s", dev_random_file, strerror(errno));
exit(1);
}

close(fd);
return r;
}


Loading…
Cancel
Save