diff --git a/benchexec/tools/ultimate.py b/benchexec/tools/ultimate.py index 219a735d9..95c358d25 100644 --- a/benchexec/tools/ultimate.py +++ b/benchexec/tools/ultimate.py @@ -475,11 +475,16 @@ def get_java_installations(self): "/usr/lib/jvm/java-*-openjdk-amd64/bin/java", ] - candidates = [c for entry in candidates for c in glob.glob(entry)] + candidates_extended = [] + for c in candidates: + if "*" in c: + candidates_extended += glob.glob(c) + else: + candidates_extended += [c] pattern = r'"(\d+\.\d+).*"' rtr = {} - for c in candidates: + for c in candidates_extended: candidate = shutil.which(c) if not candidate: continue