Fix build - potential use before initialization
Change-Id: I5d9db13b0241af64fa8e9eb9528a6e460166f280
This commit is contained in:
parent
13469e8b00
commit
e7cec81846
1 changed files with 1 additions and 1 deletions
|
@ -117,7 +117,7 @@ namespace Util
|
|||
// a poor fallback but something.
|
||||
std::vector<char> random = getBytes(length);
|
||||
int fd = open("/dev/urandom", O_RDONLY);
|
||||
int len;
|
||||
int len = 0;
|
||||
if (fd < 0 ||
|
||||
(len = read(fd, random.data(), length)) < 0 ||
|
||||
size_t(len) < length)
|
||||
|
|
Loading…
Reference in a new issue