[pve-devel] [PATCH container 3/4] parse pct config: remove "\s*" from multi-line comment regex
Stefan Sterz
s.sterz at proxmox.com
Thu Feb 24 15:21:50 CET 2022
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 at proxmox.com>
---
src/PVE/LXC/Config.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/PVE/LXC/Config.pm b/src/PVE/LXC/Config.pm
index 0ed7bd2..548f07c 100644
--- a/src/PVE/LXC/Config.pm
+++ b/src/PVE/LXC/Config.pm
@@ -943,7 +943,7 @@ sub parse_pct_config {
next;
}
- if ($line =~ m/^\#(.*)\s*$/) {
+ if ($line =~ m/^\#(.*)$/) {
$descr .= PVE::Tools::decode_text($1) . "\n";
next;
}
--
2.30.2
More information about the pve-devel
mailing list