From 7fcd15e93a1b69b6c2080c3d6090ece787862685 Mon Sep 17 00:00:00 2001 From: Daniel Neus Date: Fri, 6 Jan 2017 15:28:49 +0100 Subject: Return 0 bits in Darwin_SecRandom::poll on SecRandomCopyBytes failure --- src/lib/entropy/darwin_secrandom/darwin_secrandom.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib/entropy/darwin_secrandom/darwin_secrandom.cpp b/src/lib/entropy/darwin_secrandom/darwin_secrandom.cpp index b53e4061e..1e3613615 100644 --- a/src/lib/entropy/darwin_secrandom/darwin_secrandom.cpp +++ b/src/lib/entropy/darwin_secrandom/darwin_secrandom.cpp @@ -23,6 +23,8 @@ size_t Darwin_SecRandom::poll(RandomNumberGenerator& rng) rng.add_entropy(buf.data(), buf.size()); return buf.size() * 8; } + + return 0; } } -- cgit v1.2.3