mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 03:06:37 +00:00
92_FileLog.pm: mkdir unexisting log-directory components (Forum #122913)
git-svn-id: https://svn.fhem.de/fhem/trunk@24967 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
c9644f05a1
commit
5e4b944232
@ -185,6 +185,7 @@ FileLog_Define($@)
|
|||||||
my @t = localtime;
|
my @t = localtime;
|
||||||
my $f = ResolveDateWildcards($a[2], @t);
|
my $f = ResolveDateWildcards($a[2], @t);
|
||||||
if(!$hash->{READONLY}) {
|
if(!$hash->{READONLY}) {
|
||||||
|
restoreDir_mkDir($f=~m,^/,? "":".", $f, 1);
|
||||||
$fh = new IO::File ">>$f";
|
$fh = new IO::File ">>$f";
|
||||||
return "Can't open $f: $!" if(!defined($fh));
|
return "Can't open $f: $!" if(!defined($fh));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user