Remove unused url_scheme function.

This commit is contained in:
Michael Drake 2014-10-26 10:07:12 +00:00
parent f7781a8778
commit d732b0c769
2 changed files with 0 additions and 35 deletions

View File

@ -287,29 +287,6 @@ static void url_destroy_components(const struct url_components *components)
}
/* exported interface documented in utils/url.h */
nserror url_scheme(const char *url, char **result)
{
nserror status;
struct url_components components;
assert(url);
status = url_get_components(url, &components);
if (status == NSERROR_OK) {
if (!components.scheme) {
status = NSERROR_NOT_FOUND;
} else {
*result = strdup(components.scheme);
if (!(*result))
status = NSERROR_NOMEM;
}
}
url_destroy_components(&components);
return status;
}
/* exported interface documented in utils/url.h */
nserror url_path(const char *url, char **result)
{

View File

@ -65,18 +65,6 @@ nserror url_init(void);
bool url_host_is_ip_address(const char *host);
/**
* Return the scheme name from an URL.
*
* See RFC 3986, 3.1 for reference.
*
* \param url an absolute URL
* \param result pointer to pointer to buffer to hold scheme name
* \return NSERROR_OK on success
*/
nserror url_scheme(const char *url, char **result);
/**
* Attempt to find a nice filename for a URL.
*