Revision f155b6e4
Added by Phil Davis over 9 years ago
usr/local/www/pkg.php | ||
---|---|---|
56 | 56 |
$pkg_realpath = realpath($pkg_full_path); |
57 | 57 |
if (empty($pkg_realpath)) { |
58 | 58 |
$path_error = sprintf(gettext("ERROR: Package path %s not found."), htmlspecialchars($pkg_full_path)); |
59 |
} else { |
|
60 |
if (substr_compare($pkg_realpath, $pkg_xml_prefix, 0, strlen($pkg_xml_prefix))) { |
|
61 |
$path_error = sprintf(gettext("ERROR: Invalid path %s specified."), htmlspecialchars($pkg_full_path)); |
|
62 |
} |
|
59 |
} else if (substr_compare($pkg_realpath, $pkg_xml_prefix, 0, strlen($pkg_xml_prefix))) { |
|
60 |
$path_error = sprintf(gettext("ERROR: Invalid path %s specified."), htmlspecialchars($pkg_full_path)); |
|
63 | 61 |
} |
64 | 62 |
|
65 | 63 |
if (!empty($path_error)) { |
Also available in: Unified diff
pkg.php consolidate else-if statement