prtwash: escape metacharacters in pkgfile variables

This commit is contained in:
John McQuah 2024-02-13 15:08:54 +00:00
parent dfe2a87820
commit e9ba2b5909

View File

@ -127,6 +127,9 @@ sub parse_pkgfile {
}
}
close(PIPE);
# thanks GazL for the reminder to escape any metacharacters
$name =~ s/[.+]/\\$&/g;
$version =~ s/[.+]/\\$&/g;
return \$name, \$version, \$release, \@source, \@renames;
}