diff options
author | Edward Thomson <ethomson@edwardthomson.com> | 2019-12-01 14:00:49 +1100 |
---|---|---|
committer | Edward Thomson <ethomson@edwardthomson.com> | 2020-01-24 09:54:29 -0600 |
commit | 471daeea559ada7ac215806d55f2f686e7389608 (patch) | |
tree | c283027795a31511782327a4307a6a639e325762 /src/net.h | |
parent | 297c61e41f23caacb39d8c00957fd5ec050c9cbf (diff) | |
download | libgit2-471daeea559ada7ac215806d55f2f686e7389608.tar.gz |
net: refactor gitno redirect handling
Move the redirect handling into `git_net_url` for consistency.
Diffstat (limited to 'src/net.h')
-rw-r--r-- | src/net.h | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -30,6 +30,12 @@ extern bool git_net_url_valid(git_net_url *url); /** Returns nonzero if the URL is on the default port. */ extern int git_net_url_is_default_port(git_net_url *url); +/* Applies a redirect to the URL with a git-aware service suffix. */ +extern int git_net_url_apply_redirect( + git_net_url *url, + const char *redirect_location, + const char *service_suffix); + /** Swaps the contents of one URL for another. */ extern void git_net_url_swap(git_net_url *a, git_net_url *b); |