From d997c794872ab0224317395755bff7390aa27bfe Mon Sep 17 00:00:00 2001 From: Pomin Wu Date: Mon, 2 May 2016 21:38:29 +0800 Subject: [PATCH] Fixed #3577 (#3578) Initialize `upgradable` before use. --- lib/ansible/modules/packaging/os/apt.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ansible/modules/packaging/os/apt.py b/lib/ansible/modules/packaging/os/apt.py index 6f116907da8..450579eadd7 100644 --- a/lib/ansible/modules/packaging/os/apt.py +++ b/lib/ansible/modules/packaging/os/apt.py @@ -263,6 +263,7 @@ def package_status(m, pkgname, version, cache, state): provided_packages = cache.get_providing_packages(pkgname) if provided_packages: is_installed = False + upgradable = False # when virtual package providing only one package, look up status of target package if cache.is_virtual_package(pkgname) and len(provided_packages) == 1: package = provided_packages[0]