70_ZoneMinder: made Crypt dependency for v 1.30 optional

git-svn-id: https://svn.fhem.de/fhem/trunk@24022 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
delmar
2021-03-20 13:20:15 +00:00
parent 78c94c6de9
commit 356745853c
2 changed files with 7 additions and 1 deletions

View File

@@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- change: 70_ZoneMinder: made Crypt dependency for v 1.30 optional
- change: 48_BlinkCamera: Change to new Blink login API / add resetUniqueID
- change: 47_OBIS: redesign of parser (major change)
- bugfix: 57_Calendar: avoid spurious re-creation of all events

View File

@@ -34,7 +34,6 @@ package main;
use strict;
use warnings;
use HttpUtils;
use Crypt::MySQL qw(password41);
use DevIo;
use Digest::MD5 qw(md5 md5_hex md5_base64);
@@ -700,6 +699,12 @@ sub ZoneMinder_calcAuthHash {
my ($hash) = @_;
my $name = $hash->{NAME};
eval 'use Crypt::MySQL qw(password41)';
if($@) {
Log3 $name, 0, "ZoneMinder ($name) - ERROR: Crypt::MySQL required for auth-hash support in ZoneMinder 1.30. Please install Crypt::MySQL (or upgrade to ZoneMinder 1.32+)";
return $name;
}
Log3 $name, 4, "ZoneMinder ($name) - calling calcAuthHash";
my ($sec,$min,$curHour,$dayOfMonth,$curMonth,$curYear,$wday,$yday,$isdst) = localtime();