summaryrefslogtreecommitdiff
path: root/tests/uri-parsing-test.c
diff options
context:
space:
mode:
authorRyan Gonzalez <rymg19@gmail.com>2021-03-07 15:47:21 -0600
committerPatrick Griffis <tingping@tingping.se>2021-03-08 16:24:44 +0000
commitf33439899b0739a10de47baf50552d1c7eb58d77 (patch)
tree52289bc1d5d15cacd714121d0fd06b4e6b273431 /tests/uri-parsing-test.c
parentf9061aada1b6eff651843e830406d1d8af1bd9bb (diff)
downloadlibsoup-f33439899b0739a10de47baf50552d1c7eb58d77.tar.gz
soup-uri: Don't attempt to resolve relative paths in data URLs
RFC2397 states that data URLs have "no relative URL forms", but soup_uri_new_with_base would still attempt to resolve any suspected relative URL paths regardless. This was also inconsistent with the behavior of most web browsers.
Diffstat (limited to 'tests/uri-parsing-test.c')
-rw-r--r--tests/uri-parsing-test.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/uri-parsing-test.c b/tests/uri-parsing-test.c
index d463f1f4..07ef96b2 100644
--- a/tests/uri-parsing-test.c
+++ b/tests/uri-parsing-test.c
@@ -525,7 +525,10 @@ static const DataURITest data_tests[] = {
"" },
{ "data:text/plain,",
"text/plain",
- "" }
+ "" },
+ { "data:,a/../b",
+ "text/plain;charset=US-ASCII",
+ "a/../b" }
};
static void