aboutsummaryrefslogtreecommitdiff
path: root/bpkg/fetch.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2015-10-14 15:51:55 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2015-10-14 15:51:55 +0200
commit108c54f8ae62453a76d05e31ad477efd3559e65a (patch)
treef2c678117ddebf736f6dce536af03560c8c12bdb /bpkg/fetch.cxx
parent5f21e03ff813d9ef2b1d7c2a91f563faf6ae8572 (diff)
Move check for empty archive file up the call stack
Diffstat (limited to 'bpkg/fetch.cxx')
-rw-r--r--bpkg/fetch.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/bpkg/fetch.cxx b/bpkg/fetch.cxx
index 494b63d..2306d4e 100644
--- a/bpkg/fetch.cxx
+++ b/bpkg/fetch.cxx
@@ -467,7 +467,7 @@ namespace bpkg
static string
to_url (const string& host, uint16_t port, const path& file)
{
- assert (!file.empty () && file.relative ());
+ assert (file.relative ());
if (*file.begin () == "..")
fail << "invalid URL path " << file;
@@ -680,7 +680,7 @@ namespace bpkg
const path& a,
const dir_path& d)
{
- assert (a.relative ());
+ assert (!a.empty () && a.relative ());
assert (rl.remote () || rl.absolute ());
path f (rl.path () / a);