From e564cfb82f28fa24ed842ee96e2addf41180700d Mon Sep 17 00:00:00 2001
From: Anthony Ramine
Date: Fri, 2 Jan 2015 16:04:33 +0100
Subject: Properly parse URI fragments
This fixes a bug in httpc where redirection URIs could lead to bad requests if they
contained fragments.
---
lib/inets/doc/src/http_uri.xml | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
(limited to 'lib/inets/doc/src')
diff --git a/lib/inets/doc/src/http_uri.xml b/lib/inets/doc/src/http_uri.xml
index e64c375bba..acbd79b201 100644
--- a/lib/inets/doc/src/http_uri.xml
+++ b/lib/inets/doc/src/http_uri.xml
@@ -63,6 +63,7 @@ host() = string()
port() = pos_integer()
path() = string() - Representing a file path or directory path
query() = string()
+fragment() = string()
]]>
@@ -92,13 +93,16 @@ query() = string()
URI = uri()
Options = [Option]
Option = {ipv6_host_with_brackets, boolean()} |
- {scheme_defaults, scheme_defaults()}]
- Result = {Scheme, UserInfo, Host, Port, Path, Query}
+ {scheme_defaults, scheme_defaults()} |
+ {fragment, boolean()}]
+ Result = {Scheme, UserInfo, Host, Port, Path, Query} |
+ {Scheme, UserInfo, Host, Port, Path, Query, Fragment}
UserInfo = user_info()
Host = host()
Port = pos_integer()
Path = path()
Query = query()
+ Fragment = fragment()
Reason = term()
@@ -111,6 +115,9 @@ query() = string()
a scheme not found in the scheme defaults) a port number must be
provided or else the parsing will fail.
+ If the fragment option is true, the URI fragment will be returned as
+ part of the parsing result, otherwise it is completely ignored.
+
--
cgit v1.2.3