From e4c22fd4b9ba9782acd0c0a10866cbeaf8be694d Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Sat, 17 Apr 2021 19:03:11 +0300 Subject: Fix pkg-build crashing on empty repository location --- bpkg/pkg-build.cxx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bpkg/pkg-build.cxx b/bpkg/pkg-build.cxx index 66e158c..9d9b384 100644 --- a/bpkg/pkg-build.cxx +++ b/bpkg/pkg-build.cxx @@ -2600,6 +2600,9 @@ namespace bpkg { string l (a, p); + if (l.empty ()) + fail << "empty repository location in '" << a << "'"; + // Search for the repository location in the database before trying // to parse it. Note that the straight parsing could otherwise fail, // being unable to properly guess the repository type. -- cgit v1.1