From b895ba115548e1ae6d17e11f7c95a895195f0e94 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Tue, 18 Jul 2017 13:31:20 +0300 Subject: Adapt to non-optional task target --- bbot/worker/worker.cxx | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) (limited to 'bbot') diff --git a/bbot/worker/worker.cxx b/bbot/worker/worker.cxx index e3da1dd..a078498 100644 --- a/bbot/worker/worker.cxx +++ b/bbot/worker/worker.cxx @@ -426,20 +426,12 @@ startup () // Find the environment setup executable. // - string tg; - process_path pp; - - if (tm.target) - { - tg = tm.target->string (); - - // While the executable path contains a directory (so the PATH search - // does not apply) we still use process::path_search() to automatically - // handle appending platform-specific executable extensions (.exe/.bat, - // etc). - // - pp = process::try_path_search (env_dir / tg, false); - } + // While the executable path contains a directory (so the PATH search does + // not apply) we still use process::path_search() to automatically handle + // appending platform-specific executable extensions (.exe/.bat, etc). + // + string tg (tm.target.string ()); + process_path pp (process::try_path_search (env_dir / tg, false)); if (pp.empty ()) pp = process::try_path_search (env_dir / "default", false); -- cgit v1.1