From: Derrick Stolee Date: Mon, 01 Aug 2022 14:00:30 GMT Subject: Re: [PATCH 4/5] bundle-uri: add support for http(s):// and file:// Message-ID: <6621a20d-9857-2150-258f-f229cea525dd@github.com> In-Reply-To: On 7/27/2022 6:09 PM, Josh Steadmon wrote: > On 2022.07.25 20:34, Derrick Stolee via GitGitGadget wrote: >> +static int copy_uri_to_file(const char *filename, const char *uri) >> +{ >> + const char *out; >> + >> + if (skip_prefix(uri, "https:", &out) || >> + skip_prefix(uri, "http:", &out)) >> + return download_https_uri_to_file(filename, uri); > > Since we're not using "out" here, should we replace the skip_prefix()s > with starts_with(), or perhaps even istarts_with()? Sounds good to me. Can't abandon "out" because it is used for the "file://" prefix, but istarts_with() is better here. Thanks, -Stolee