[54715] trunk/base/src/port1.0/portlint.tcl
jmr at macports.org
jmr at macports.org
Fri Jul 31 15:58:04 PDT 2009
Revision: 54715
http://trac.macports.org/changeset/54715
Author: jmr at macports.org
Date: 2009-07-31 15:58:03 -0700 (Fri, 31 Jul 2009)
Log Message:
-----------
make lint detect unsafe characters in port names (#20495)
Modified Paths:
--------------
trunk/base/src/port1.0/portlint.tcl
Modified: trunk/base/src/port1.0/portlint.tcl
===================================================================
--- trunk/base/src/port1.0/portlint.tcl 2009-07-31 22:53:24 UTC (rev 54714)
+++ trunk/base/src/port1.0/portlint.tcl 2009-07-31 22:58:03 UTC (rev 54715)
@@ -328,6 +328,13 @@
ui_info "OK: Found optional variable: $opt_var"
}
}
+
+ if {[info exists name]} {
+ if {[regexp {(![[:alnum:]_.-])*} $name]} {
+ ui_error "Port name '$name' contains unsafe characters. Names should only contain alphanumeric characters, underscores, dashes or dots."
+ incr errors
+ }
+ }
if {[info exists platforms]} {
foreach platform $platforms {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090731/f10ef4fb/attachment.html>
More information about the macports-changes
mailing list