aboutsummaryrefslogtreecommitdiff
path: root/bbot/worker/worker.cxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2021-12-09 15:51:42 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2021-12-09 15:51:42 +0300
commit7d8fe34a06781153f42c533ae7e303b3c5daf575 (patch)
treef6cee5d1607297b67fcda450237b0f4b8610143d /bbot/worker/worker.cxx
parentcf7196939af82155b329eddb7528cbbf9759b423 (diff)
Add support for multiple requirements in requirement alternative
Diffstat (limited to 'bbot/worker/worker.cxx')
-rw-r--r--bbot/worker/worker.cxx8
1 files changed, 7 insertions, 1 deletions
diff --git a/bbot/worker/worker.cxx b/bbot/worker/worker.cxx
index d6e8cad..e4b5e5e 100644
--- a/bbot/worker/worker.cxx
+++ b/bbot/worker/worker.cxx
@@ -1270,7 +1270,13 @@ build (size_t argc, const char* argv[])
tm.requirements.end (),
[id] (const requirement_alternatives& r)
{
- return r.size () == 1 && r[0] == id;
+ if (r.size () == 1)
+ {
+ const requirement_alternative& a (r[0]);
+ return find (a.begin (), a.end (), id) != a.end ();
+ }
+
+ return false;
}) != tm.requirements.end ();
};