Skip to content

Commit

Permalink
migw: Fix build failure
Browse files Browse the repository at this point in the history
  • Loading branch information
tatsuhiro-t committed Jan 22, 2016
1 parent d648062 commit 6da1e99
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/SimpleRandomizer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -67,14 +67,16 @@ namespace {
std::random_device rd;
} // namespace

SimpleRandomizer::SimpleRandomizer() : gen_(rd())
{
#ifdef __MINGW32__
SimpleRandomizer::SimpleRandomizer()
{
BOOL r = ::CryptAcquireContext(&provider_, 0, 0, PROV_RSA_FULL,
CRYPT_VERIFYCONTEXT | CRYPT_SILENT);
assert(r);
#endif
}
#else // !__MINGW32__
SimpleRandomizer::SimpleRandomizer() : gen_(rd()) {}
#endif // !__MINGW32__

SimpleRandomizer::~SimpleRandomizer()
{
Expand Down

0 comments on commit 6da1e99

Please sign in to comment.