Skip to content

Commit

Permalink
Cleaning up svr4pkg commit fix for ansible#7645
Browse files Browse the repository at this point in the history
  • Loading branch information
jimi-c committed Jun 9, 2014
1 parent fadf02d commit 7059528
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions library/packaging/svr4pkg
Original file line number Diff line number Diff line change
Expand Up @@ -209,18 +209,18 @@ def main():
(rc, out, err) = package_uninstall(module, name, src, category)
out = out[:75]

#Success,Warning,Interruption,Reboot all,Reboot this return codes
if rc is 0 or rc is 2 or rc is 3 or rc is 10 or rc is 20:
# Success, Warning, Interruption, Reboot all, Reboot this return codes
if rc in (0, 2, 3, 10, 20):
result['changed'] = True
#no install nor uninstall, or failed
# no install nor uninstall, or failed
else:
result['changed'] = False
#Fatal error,Administration,Administration Interaction return codes
if rc is 1 or rc is 4 or rc is 5:
result['failed'] = True

# Fatal error, Administration, Administration Interaction return codes
if rc in (1, 4 , 5):
result['failed'] = True
else:
result['failed'] = False
result['failed'] = False

if out:
result['stdout'] = out
Expand Down

0 comments on commit 7059528

Please sign in to comment.