escape {} in regexp

This commit is contained in:
Isaac Connor 2018-07-01 18:19:11 -04:00
parent 10531df543
commit 76abad0a96
1 changed files with 1 additions and 1 deletions

View File

@ -654,7 +654,7 @@ sub jsonDecode {
$out =~ s/=>null/=>undef/g;
$out =~ s/`/'/g;
$out =~ s/qx/qq/g;
( $out ) = $out =~ m/^({.+})$/; # Detaint and check it's a valid object syntax
( $out ) = $out =~ m/^(\{.+\})$/; # Detaint and check it's a valid object syntax
my $result = eval $out;
Fatal( $@ ) if ( $@ );
return( $result );