parse datacenter config: remove "\s*" from comment regex

To be consistent with PBS's implementation of multi-line comments
remove "\s*" here too. Since the regex isn't lazy .* matches
everything \s* would anyway. (Note that new lines occurs after "$").

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
This commit is contained in:
Stefan Sterz 2022-02-24 15:21:48 +01:00 committed by Thomas Lamprecht
parent 0cc6e73740
commit 09b9955053

View file

@ -264,7 +264,7 @@ sub parse_datacenter_config {
# description may be comment or key-value pair (or both)
my $comment = '';
for my $line (split(/\n/, $raw)) {
if ($line =~ /^\#(.*)\s*$/) {
if ($line =~ /^\#(.*)$/) {
$comment .= PVE::Tools::decode_text($1) . "\n";
}
}