aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2020-09-03 10:47:12 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2020-09-03 12:11:46 +0300
commit3986a17f6b461516a5c9a933b1ae3a79c692d0bf (patch)
treea010780bf7235794e8c0c18b2dd01f43e1b50e2d
parentda8e0673fc1e10aa0adede2d0186155787c940bc (diff)
Add support for IP4/6 host types for repository URL
Note: still need to implement IPv4/6 addresses normalization and probably change the documentation.
-rw-r--r--libbpkg/manifest.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/libbpkg/manifest.cxx b/libbpkg/manifest.cxx
index 3df1726..7514357 100644
--- a/libbpkg/manifest.cxx
+++ b/libbpkg/manifest.cxx
@@ -3153,12 +3153,12 @@ namespace bpkg
if (!authority || authority->host.empty ())
bad_url ("invalid host");
- if (authority->host.kind != url_host_kind::name)
- bad_url ("unsupported host type");
-
// Normalize the host name.
//
- lcase (authority->host.value);
+ // @@ Also add IPv4/6 addresses normalization.
+ //
+ if (authority->host.kind == url_host_kind::name)
+ lcase (authority->host.value);
// We don't distinguish between the absent and empty paths for the
// remote repository URLs.