summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorPaul Varner <fuzzyray@gentoo.org>2009-05-20 21:46:46 +0000
committerZac Medico <zmedico@gentoo.org>2013-01-18 18:25:46 -0800
commitf8960360ebca8ae85b91e24047afc21f6eda33bb (patch)
tree3538b12cf2a023d658aa9501d0a0b5fecadfbe66 /bin
parentd038b754d2423e21326939a5fb56564efe9d84bd (diff)
downloadportage-f8960360ebca8ae85b91e24047afc21f6eda33bb.tar.gz
portage-f8960360ebca8ae85b91e24047afc21f6eda33bb.tar.bz2
portage-f8960360ebca8ae85b91e24047afc21f6eda33bb.zip
Change behaviour of getMinUpgrade
This allows to differentiate between situations where the system is unaffected and unexistance of an upgrade path. Previously, the glsa-check would treat GLSAs that had no upgrade path (such as mask glsas) as not affecting the system. svn path=/trunk/gentoolkit/; revision=647 http://git.overlays.gentoo.org/gitweb/?p=proj/gentoolkit.git;a=commit;h=ef38a394c5c2f5901173a53914705730850f9b3f
Diffstat (limited to 'bin')
-rw-r--r--[-rwxr-xr-x]bin/glsa-check10
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/glsa-check b/bin/glsa-check
index 0e2b7a3d4..969ad84fb 100755..100644
--- a/bin/glsa-check
+++ b/bin/glsa-check
@@ -207,6 +207,11 @@ if mode in ["dump", "fix", "inject", "pretend"]:
elif mode == "fix":
sys.stdout.write("fixing "+myid+"\n")
mergelist = myglsa.getMergeList(least_change=least_change)
+ if mergelist == None:
+ sys.stdout.write(">>> no vulnerable packages installed\n")
+ elif mergelist == []:
+ sys.stdout.write(">>> cannot fix GLSA, no unaffected packages available\n")
+ sys.exit(2)
for pkg in mergelist:
sys.stdout.write(">>> merging "+pkg+"\n")
# using emerge for the actual merging as it contains the dependency
@@ -225,6 +230,11 @@ if mode in ["dump", "fix", "inject", "pretend"]:
elif mode == "pretend":
sys.stdout.write("Checking GLSA "+myid+"\n")
mergelist = myglsa.getMergeList(least_change=least_change)
+ if mergelist == None:
+ sys.stdout.write(">>> no vulnerable packages installed\n")
+ elif mergelist == []:
+ sys.stdout.write(">>> cannot fix GLSA, no unaffected packages available\n")
+ sys.exit(2)
if mergelist:
sys.stdout.write("The following updates will be performed for this GLSA:\n")
for pkg in mergelist: