Browse files

Merge branch 'master' of github.com:agentzh/sshbatch

  • Loading branch information...
2 parents 4097010 + ed59bcc commit 4821258fc01641173d00684c85794a51c68a91db @agentzh committed Aug 5, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/SSH/Batch/ForNodes.pm
View
4 lib/SSH/Batch/ForNodes.pm
@@ -72,7 +72,7 @@ sub parse_line ($$) {
my $rcfile = $_[1];
if (/^\s*([^=\s]*)\s*=\s*(.*)/) {
my ($var, $def) = ($1, $2);
- if ($var !~ /^[-\w]+$/) {
+ if ($var !~ /^\S+$/) {
die "Invalid variable name in $rcfile, line $.: ",
"$var\n";
}
@@ -179,7 +179,7 @@ sub parse_term ($) {
local *_ = \($_[0]);
if (/^ \{ ( [^}\s]* ) \} $/x) {
my $var = $1;
- if ($var !~ /^[-\w]+$/) {
+ if ($var !~ /^\S+$/) {
die "Invalid variable name in term $_: $var\n";
}
my $set = $Vars{$var};

0 comments on commit 4821258

Please sign in to comment.