Merge remote-tracking branch 'origin/develop' into ent-9662-second-round

This commit is contained in:
daniel 2023-03-15 21:24:05 +01:00
commit 63ad563bf2
1 changed files with 7 additions and 2 deletions

View File

@ -743,8 +743,12 @@ while (my ($key, $value) = each (@{$plugin_setup{"log"}})) {
if (defined($value->{"log_location_multiple"})){ if (defined($value->{"log_location_multiple"})){
$log_filename_multiple = $value->{"log_location_multiple"}; $log_filename_multiple = $value->{"log_location_multiple"};
$log_create_module_for_each_log = $value->{"module_for_each_log"}; $log_create_module_for_each_log = $value->{"module_for_each_log"};
#my @buffer = `dir "$log_filename_multiple" /b /a-d`; my @buffer;
my @buffer = `ls -d "$log_filename_multiple"`; if($^O =~ /win/i){
@buffer = `dir "$log_filename_multiple" /b /a-d`;
}else{
@buffer = `ls -d "$log_filename_multiple"`;
}
foreach (@buffer) { foreach (@buffer) {
# This should solve problems with carriage return in Unix, Linux and Windooze # This should solve problems with carriage return in Unix, Linux and Windooze
chomp($_); chomp($_);
@ -757,6 +761,7 @@ while (my ($key, $value) = each (@{$plugin_setup{"log"}})) {
$module_name_multiple =~ s/\//_/g; $module_name_multiple =~ s/\//_/g;
$module_name_multiple = $module_name . "_" . $module_name_multiple; $module_name_multiple = $module_name . "_" . $module_name_multiple;
} }
$log_filename = $log_filename_multiple . $_;
manage_logfile ($log_filename, $module_name_multiple, $readall, $type, $regexp, $description); manage_logfile ($log_filename, $module_name_multiple, $readall, $type, $regexp, $description);
} }
} }