diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 9b758246bb..59004de345 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -3680,20 +3680,17 @@ sub write_module_xml ($@) { # Is it an extraction log module? if($module->{'type'} eq "log"){ + my $output = join('', @data); + + if ($output eq "") { + return; + } + $Xml .="\n"; $Xml .= " {'name'} . "]]>\n"; $Xml .= " {'type'} . "]]>\n"; $Xml .= " base64\n"; - - # Data list - if ($#data > 0) { - $Xml .= " \n"; - # Single data - } else { - chomp ($data[0]); - $Xml .= " \n"; - } - + $Xml .= " \n"; $Xml .= "\n"; return; }