pck-update,libnetwork.lib: a package name can contain one or more undescores so add _ to the list of allowed characters

Signed-off-by: Davide Madrisan <davide.madrisan@gmail.com>
This commit is contained in:
Davide Madrisan 2012-06-18 21:55:25 +02:00
parent a14b989d3a
commit b856cd2959
3 changed files with 8 additions and 2 deletions

View File

@ -8,6 +8,12 @@ Changes in version 1.12.3
(when DISTRO_rpm="mamba2" is set in the configuration files).
Feature asked by Silvan Calarco.
+ bugfix
* pck-update, libnetwork.lib - Davide Madrisan:
A package name can contain one or more undescores so add it to the list of
allowed characters in 'repository.get_srpm_pckname_from_site()'.
(Problem pointed out by Silvan Calarco.)
-------------------------------------------------------------------------------
Changes in version 1.12.2

View File

@ -94,7 +94,7 @@ function repository.get_srpm_pckname_from_site() {
notify.debug "$FUNCNAME: infile = \"$infile\""
local regexpr
[[ "$pck_name" =~ ^[a-zA-Z0-9-]+$ ]] && \
[[ "$pck_name" =~ ^[a-zA-Z0-9_-]+$ ]] && \
regexpr="^$pck_name-[^-]\+-[^-]\+$" || regexpr="$pck_name"
notify.debug "$FUNCNAME: regexpr = \"$regexpr\""

View File

@ -886,7 +886,7 @@ echo -n "\"${define_list_value[$i]}\" "; done)]"
notify.debug "\
define_list_rpm = \"$define_list_rpm\""
if [[ "$pck_name" =~ ^[a-zA-Z0-9-]+$ ]]; then
if [[ "$pck_name" =~ ^[a-zA-Z0-9_-]+$ ]]; then
if [ "$pck_newver" ]; then
notify.note $"updating package ${NOTE}${pck_name##*/}${NORM} \
to version ${NOTE}${pck_newver}${NORM}""..."