From c004b0f6b8dd0ede917b90060fb0c97a91a239d2 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Tue, 7 Jul 2020 20:35:31 +0300 Subject: Fix crash when absolute path for 'source' sub-option is specified --- bdep/new.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bdep/new.cxx b/bdep/new.cxx index d2a4229..318d4aa 100644 --- a/bdep/new.cxx +++ b/bdep/new.cxx @@ -426,6 +426,10 @@ namespace bdep : nullptr) : nullptr); + if (source != nullptr && source->absolute ()) + fail << "invalid value '" << *source << "' for option " + << "--type|-t,source: absolute path"; + // Validate vcs options. // vcs vc (o.vcs ()); -- cgit v1.1