From: Todd C. Miller Date: Tue, 7 Apr 2015 16:15:45 +0000 (-0600) Subject: Fix setting of pp_rpm_version when there is no patchlevel present. X-Git-Tag: SUDO_1_8_14^2~173 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6d63ca32fb0dba80497d09d1c40fddae13e5b348;p=sudo Fix setting of pp_rpm_version when there is no patchlevel present. Also tighten up the regexp for pp_rpm_release. --- diff --git a/sudo.pp b/sudo.pp index d78db42fd..930cc5b20 100644 --- a/sudo.pp +++ b/sudo.pp @@ -41,8 +41,8 @@ still allow people to get their work done." %if [rpm,deb] # Convert patch level into release and remove from version - pp_rpm_release="`expr \( $version : '.*p\([0-9][0-9]*\)' \| 0 \) + 1`" - pp_rpm_version="`expr $version : '\(.*\)p[0-9][0-9]*'`" + pp_rpm_release="`expr \( $version : '.*p\([0-9][0-9]*\)$' \| 0 \) + 1`" + pp_rpm_version="`expr \( $version : '\(.*\)p[0-9][0-9]*$' \| $version \)`" pp_rpm_license="BSD" pp_rpm_url="http://www.sudo.ws/" pp_rpm_group="Applications/System"