Disable accidental interpolation in regular expression

Without this change, Perl prints the following warning:

> Possible unintended interpolation of `@$` in string at ddclient line 43.
This commit is contained in:
Richard Hansen 2020-06-29 14:21:29 -04:00
parent dde91fd028
commit c72d128a9e

View file

@ -40,7 +40,7 @@ my $hostname = hostname();
# to run this file as a Perl script before those substitutions are made.
sub subst_var {
my ($subst, $default) = @_;
return $default if $subst =~ /^@\w+@$/a;
return $default if $subst =~ qr'^@\w+@$'a;
return $subst;
}