Removed duplicate check in random_seed test - bug #140

This commit is contained in:
Alexandru Costache
2014-07-04 11:58:14 +03:00
committed by alexandru.costache
parent d4e81f9ec8
commit 4841c48f81

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;
}