Bug 673621 - wrong %preun scriplet
Summary: wrong %preun scriplet
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: subscription-manager
Version: 6.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Bryan Kearney
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks: 568421
TreeView+ depends on / blocked
 
Reported: 2011-01-28 23:08 UTC by Miroslav Suchý
Modified: 2011-05-19 13:39 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-05-19 13:39:20 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2011:0611 0 normal SHIPPED_LIVE new package: subscription-manager 2011-05-18 17:56:21 UTC

Description Miroslav Suchý 2011-01-28 23:08:04 UTC
In spec file is:
%preun
if [ $1 = 0 ] ; then

'=' compares strings

there should be:
%preun
if [ $1 -eq 0 ] ; then

Comment 2 Bryan Kearney 2011-01-31 15:01:09 UTC
fixed in 8bc643b58db8e1b329fea358384dc61b2fd4fe7f

Comment 5 J.C. Molet 2011-02-21 13:59:29 UTC
[jmolet@jmolet subscription-manager]$ git branch 
* RHEL6
  master
[jmolet@jmolet subscription-manager]$ grep "%preun" -A 1 subscription-manager.spec 
%preun
if [ $1 -eq 0 ] ; then



[jmolet@jmolet subscription-manager]$ git checkout master
Switched to branch 'master'
[jmolet@jmolet subscription-manager]$ grep "%preun" -A 1 subscription-manager.spec 
%preun
if [ $1 -eq 0 ] ; then


^^ this has been verified against master and rhel6 branches

Comment 6 Miroslav Suchý 2011-02-21 15:13:54 UTC
?!
I'm not sure this is how it should be tested. I would expect compartment of output:
rpm --scripts  subscription-manager.rpm
The fact that something is in git, does not mean that it will be presented in final package....

Comment 7 J.C. Molet 2011-02-21 15:53:51 UTC
My apologies, I failed to recognize that. Running your verification seems to show that this persists:

[root@jmolet-vm0 ~]# rpm -q --scripts subscription-manager
postinstall scriptlet (using /bin/sh):
chkconfig --add rhsmcertd
# /sbin/service rhsmcertd start
preuninstall scriptlet (using /bin/sh):
if [ $1 -eq 0 ] ; then
   /sbin/service rhsmcertd stop >/dev/null 2>&1
   /sbin/chkconfig --del rhsmcertd
fi


[root@jmolet-vm0 ~]# rhsm-version 
subscription-manager-0.95.1-1.git.15.c75e560.el6.x86_64


Do you need further verification?

Comment 8 errata-xmlrpc 2011-05-19 13:39:20 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2011-0611.html


Note You need to log in before you can comment on or make changes to this bug.