1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-12-04 14:46:47 -05:00

[uri] URI_HOST_PORT

This commit is contained in:
Witold Filipczyk 2022-01-15 18:28:46 +01:00
parent 9d2a55d6c3
commit c56f0c5e98
4 changed files with 7 additions and 3 deletions

View File

@ -94,7 +94,7 @@ js_location_get_property_host(JSContext *ctx, JSValueConst this_val)
return JS_EXCEPTION;
}
char *str = get_uri_string(vs->uri, URI_HOST | URI_PORT);
char *str = get_uri_string(vs->uri, URI_HOST_PORT);
if (!str) {
#ifdef ECMASCRIPT_DEBUG

View File

@ -205,7 +205,7 @@ location_get_property_host(JSContext *ctx, unsigned int argc, JS::Value *vp)
return false;
}
char *str = get_uri_string(vs->uri, URI_HOST | URI_PORT);
char *str = get_uri_string(vs->uri, URI_HOST_PORT);
if (!str) {
#ifdef ECMASCRIPT_DEBUG

View File

@ -171,6 +171,8 @@ enum uri_component {
/* Used for getting the URI with no #fragment */
URI_BASE = ~(URI_RARE | URI_FRAGMENT) | URI_POST,
URI_BASE_FRAGMENT = URI_BASE | URI_FRAGMENT,
/* Used for getting data-less URI (stuff only up to the slash). */
URI_SERVER = ~(URI_RARE | URI_DATA | URI_FRAGMENT),
@ -197,6 +199,8 @@ enum uri_component {
* URI_PORT. */
URI_DNS_HOST = URI_HOST | URI_IDN,
URI_HOST_PORT = URI_HOST | URI_PORT,
/* Used for adding the unproxied URI and encode it using IDN to string */
URI_PROXY = ~(URI_RARE | URI_FRAGMENT) | URI_IDN,

View File

@ -654,7 +654,7 @@ follow_url(struct session *ses, struct uri *uri, char *target,
static int follow_url_event_id = EVENT_NONE;
char *uristring;
uristring = uri && !uri->post ? get_uri_string(uri, URI_BASE | URI_FRAGMENT)
uristring = uri && !uri->post ? get_uri_string(uri, URI_BASE_FRAGMENT)
: NULL;
/* Do nothing if we do not have a URI or if it is a POST request