mirror of
https://codeberg.org/scip/Crypt--PWSafe3.git
synced 2025-12-16 12:11:02 +01:00
Attempts to install module on the system on which Bytes::Random::Secure
was installed ended up with: Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/run.t .. 1/? # Failed test 'open a pwsafe3 database' # at t/run.t line 36. # Failed test 'read a pwsafe3 database and change a record (Undefined subroutine &Crypt::PWSafe3::random_bytes called at /home/marcink/.cpan/build/Crypt-PWSafe3-1.06-qScJdO/blib/lib/Crypt/PWSafe3.pm line 56. # )' # at t/run.t line 66. (and more such errors).
This commit is contained in:
@@ -34,7 +34,10 @@ use Crypt::PWSafe3::SHA256;
|
||||
# install a wrapper closure around the
|
||||
# one we found.
|
||||
BEGIN {
|
||||
eval { require Bytes::Random::Secure };
|
||||
eval {
|
||||
require Bytes::Random::Secure;
|
||||
Bytes::Random::Secure->import("random_bytes");
|
||||
};
|
||||
if ($@) {
|
||||
# well, didn' work, use slow function
|
||||
eval { require Crypt::Random; };# qw( makerandom ); };
|
||||
|
||||
Reference in New Issue
Block a user