From: Dietmar Maurer Date: Thu, 14 Jun 2018 07:04:47 +0000 (+0200) Subject: fix regex quoting in $print_bash_completion X-Git-Url: https://git.proxmox.com/?p=pve-common.git;a=commitdiff_plain;h=2c48a66569f4e013ace2f90b489016b471250491;hp=ea5a508493e9acac4c5a1949dd71fa081892428e fix regex quoting in $print_bash_completion Signed-off-by: Dietmar Maurer --- diff --git a/src/PVE/CLIHandler.pm b/src/PVE/CLIHandler.pm index a7ced38..acdeffe 100644 --- a/src/PVE/CLIHandler.pm +++ b/src/PVE/CLIHandler.pm @@ -316,7 +316,7 @@ my $print_bash_completion = sub { shift @$args; # no need for program name my $print_result = sub { foreach my $p (@_) { - print "$p\n" if $p =~ m/^$cur/; + print "$p\n" if $p =~ m/^\Q$cur\E/; } };