X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/071277e63e633aefca8c9760c65de2ef77ae7f67..0d7a222297c1d39c43cdb2f09ea1d5ddd03c7aa0:/tools/tesh/tesh.pl?ds=sidebyside diff --git a/tools/tesh/tesh.pl b/tools/tesh/tesh.pl index 54f053a753..2e0ec34fd6 100755 --- a/tools/tesh/tesh.pl +++ b/tools/tesh/tesh.pl @@ -342,7 +342,7 @@ sub exec_cmd { } # substitute remaining variables, if any - while ( $cmd{'cmd'} =~ /\${(\w+)(?::[=-][^}]*)?}/ ) { + while ( $cmd{'cmd'} =~ /\$\{(\w+)(?::[=-][^}]*)?\}/ ) { $cmd{'cmd'} = var_subst( $cmd{'cmd'}, $1, "" ); } while ( $cmd{'cmd'} =~ /\$(\w+)/ ) { @@ -730,11 +730,11 @@ sub build_diff { sub var_subst { my ( $text, $name, $value ) = @_; if ($value) { - $text =~ s/\${$name(?::[=-][^}]*)?}/$value/g; + $text =~ s/\$\{$name(?::[=-][^}]*)?\}/$value/g; $text =~ s/\$$name(\W|$)/$value$1/g; } else { - $text =~ s/\${$name:=([^}]*)}/$1/g; - $text =~ s/\${$name}//g; + $text =~ s/\$\{$name:=([^}]*)\}/$1/g; + $text =~ s/\$\{$name\}//g; $text =~ s/\$$name(\W|$)/$1/g; } return $text;