When the default constructor was split out into a separate function (in
r261522) I accidentally made it call _M_init("mt19937") instead of
_M_init_pretr1("mt19937"). That means it will always throw an exception,
because "mt19937" isn't a valid token accepted by the _M_init function.
Restore the original behaviour by calling _M_init_pretr1("mt19937").
* include/bits/random.h (random_device) [!_GLIBCXX_USE_DEV_RANDOM]:
Fix default constructor to call correct function.
From-SVN: r265218
2018-10-16 Jonathan Wakely <jwakely@redhat.com>
+ * include/bits/random.h (random_device) [!_GLIBCXX_USE_DEV_RANDOM]:
+ Fix default constructor to call correct function.
+
* testsuite/experimental/net/internet/address/v4/creation.cc: Do not
declare ip in global namespace, to avoid collision with struct ip
defined in <netinet/ip.h>.
~random_device()
{ _M_fini(); }
#else
- random_device() { _M_init("mt19937"); }
+ random_device() { _M_init_pretr1("mt19937"); }
explicit
random_device(const std::string& __token)