Skip to content

Commit

Permalink
Another "%p is multilevel" breakage trigger (thanks TheSin!)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmacks committed Nov 27, 2016
1 parent 8d2b4fc commit f84600d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion perlmod/Fink/Validation.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1327,11 +1327,15 @@ sub validate_info_component {
$looks_good = 0;
}

# Check for %i/.. (%p could be multilevel)
# Checks for relative pathnames that break if %p is multilevel
if ($value =~ /\%i\/\.\.([\s\/]|\Z)/) {
print "Warning: Field \"$field\"$splitoff_field appears to contain \%p/.. (did you mean \%d instead?). ($filename)\n";
$looks_good = 0;
}
if ($value =~ /\.\.\/DEBIAN([\s\/]|\Z)/) {
print "Warning: Field \"$field\"$splitoff_field appears to contain ../DEBIAN (did you mean \%d/DEBIAN instead?). ($filename)\n";
$looks_good = 0;
}

# warn for non-plain-text chars
# this doesn't work for unicode; is there a good way to accept unicode without just ignoring validation?
Expand Down

0 comments on commit f84600d

Please sign in to comment.