From 1e09e44510dcc56007ed7f91913666601eb52b79 Mon Sep 17 00:00:00 2001
From: Thomas Mullaly <thomas.mullaly@gmail.com>
Date: Sun, 25 Jul 2010 16:21:05 -0400
Subject: [PATCH] urlmon: Implemented IUri_GetPath.

---
 dlls/urlmon/tests/uri.c | 188 ++++++++++++++++++++--------------------
 dlls/urlmon/uri.c       |  26 ++++--
 2 files changed, 113 insertions(+), 101 deletions(-)

diff --git a/dlls/urlmon/tests/uri.c b/dlls/urlmon/tests/uri.c
index 5bf8ca28d49..0d03fff1835 100644
--- a/dlls/urlmon/tests/uri.c
+++ b/dlls/urlmon/tests/uri.c
@@ -102,7 +102,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},                                          /* FRAGMENT */
             {"www.winehq.org",S_OK,FALSE},                              /* HOST */
             {"",S_FALSE,FALSE},                                         /* PASSWORD */
-            {"/",S_OK,TRUE},                                            /* PATH */
+            {"/",S_OK,FALSE},                                           /* PATH */
             {"/",S_OK,TRUE},                                            /* PATH_AND_QUERY */
             {"",S_FALSE,TRUE},                                          /* QUERY */
             {"http://www.winehq.org/tests/../tests/../..",S_OK,FALSE},  /* RAW_URI */
@@ -131,7 +131,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/tests",S_OK,TRUE},
+            {"/tests",S_OK,FALSE},
             {"/tests",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://winehq.org/tests/.././tests",S_OK,FALSE},
@@ -160,7 +160,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.winehq.org",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/?query=x&return=y",S_OK,TRUE},
             {"?query=x&return=y",S_OK,TRUE},
             {"HtTp://www.winehq.org/tests/..?query=x&return=y",S_OK,FALSE},
@@ -189,7 +189,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"example.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/path/a/Forbidden'%3C%7C%3E%20Characters",S_OK,TRUE},
+            {"/path/a/Forbidden'%3C%7C%3E%20Characters",S_OK,FALSE},
             {"/path/a/Forbidden'%3C%7C%3E%20Characters",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"hTTp://us%45r%3Ainfo@examp%4CE.com:80/path/a/b/./c/../%2E%2E/Forbidden'<|> Characters",S_OK,FALSE},
@@ -219,7 +219,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.winehq.org",S_OK,FALSE},
             {"wine",S_OK,FALSE},
-            {"/dir/foo%20bar.txt",S_OK,TRUE},
+            {"/dir/foo%20bar.txt",S_OK,FALSE},
             {"/dir/foo%20bar.txt",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://winepass:wine@ftp.winehq.org:9999/dir/foo bar.txt",S_OK,FALSE},
@@ -247,7 +247,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/c:/tests/foo%2520bar.mp3",S_OK,TRUE},
+            {"/c:/tests/foo%2520bar.mp3",S_OK,FALSE},
             {"/c:/tests/foo%2520bar.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"file://c:\\tests\\../tests/foo%20bar.mp3",S_OK,FALSE},
@@ -275,7 +275,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/tests/test%20file.README.txt",S_OK,TRUE},
+            {"/tests/test%20file.README.txt",S_OK,FALSE},
             {"/tests/test%20file.README.txt",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"FILE://localhost/test dir\\../tests/test%20file.README.txt",S_OK,FALSE},
@@ -303,7 +303,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"nothing:should:happen here",S_OK,TRUE},
+            {"nothing:should:happen here",S_OK,FALSE},
             {"nothing:should:happen here",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"urn:nothing:should:happen here",S_OK,FALSE},
@@ -332,7 +332,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"127.0.0.1",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test%20dir/test.txt",S_OK,TRUE},
+            {"/test%20dir/test.txt",S_OK,FALSE},
             {"/test%20dir/test.txt",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://127.0.0.1/tests/../test dir/./test.txt",S_OK,FALSE},
@@ -361,7 +361,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"fedc:ba98:7654:3210:fedc:ba98:7654:3210",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]",S_OK,FALSE},
@@ -390,7 +390,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"::13.1.68.3",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://[::13.1.68.3]",S_OK,FALSE},
@@ -419,7 +419,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"fedc:ba98::3210",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[FEDC:BA98:0:0:0:0:0:3210]",S_OK,FALSE},
@@ -448,7 +448,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.winehq.org",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"1234://www.winehq.org",S_OK,FALSE},
@@ -477,7 +477,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/C:/test/test.mp3",S_OK,TRUE},
+            {"/C:/test/test.mp3",S_OK,FALSE},
             {"/C:/test/test.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"C:/test/test.mp3",S_OK,FALSE},
@@ -507,7 +507,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"server",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test.mp3",S_OK,TRUE},
+            {"/test.mp3",S_OK,FALSE},
             {"/test.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"\\\\Server/test.mp3",S_OK,FALSE},
@@ -536,7 +536,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.winehq.org",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test",S_OK,TRUE},
+            {"/test",S_OK,FALSE},
             {"/test",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"www.winehq.org/test",S_OK,FALSE},
@@ -566,7 +566,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.winehq.org",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test",S_OK,TRUE},
+            {"/test",S_OK,FALSE},
             {"/test",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"*:www.winehq.org/test",S_OK,FALSE},
@@ -594,7 +594,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/../some dir/test.ext",S_OK,TRUE},
+            {"/../some dir/test.ext",S_OK,FALSE},
             {"/../some dir/test.ext",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"/../some dir/test.ext",S_OK,FALSE},
@@ -622,7 +622,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"//implicit/wildcard/uri%20scheme",S_OK,TRUE},
+            {"//implicit/wildcard/uri%20scheme",S_OK,FALSE},
             {"//implicit/wildcard/uri%20scheme",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"//implicit/wildcard/uri scheme",S_OK,FALSE},
@@ -652,7 +652,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/.//google.com",S_OK,TRUE},
+            {"/.//google.com",S_OK,FALSE},
             {"/.//google.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://google.com",S_OK,FALSE},
@@ -683,7 +683,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"pass:word",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://user:pass:word@winehq.org/",S_OK,FALSE},
@@ -714,7 +714,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.google.com",S_OK,FALSE},
             {"PASS",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://w%49%4Ee:PA%53%53@ftp.google.com/",S_OK,FALSE},
@@ -745,7 +745,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.google.com",S_OK,FALSE},
             {"PA%7B%7D",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://w%5D%5Be:PA%7B%7D@ftp.google.com/",S_OK,FALSE},
@@ -776,7 +776,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.google.com",S_OK,FALSE},
             {"",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://empty:@ftp.google.com/",S_OK,FALSE},
@@ -807,7 +807,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://\" \"weird@ftp.google.com/",S_OK,FALSE},
@@ -838,7 +838,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ftp.google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://\" \"weird@ftp.google.com/",S_OK,FALSE},
@@ -868,7 +868,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"word",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://%xy:word@winehq.org/",S_OK,FALSE},
@@ -900,7 +900,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"%52%53ord",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://%2E:%52%53ord@winehq.org/",S_OK,FALSE},
@@ -930,7 +930,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"word",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://[](),'test':word@winehq.org/",S_OK,FALSE},
@@ -959,7 +959,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"test",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/?:word@winehq.org/",S_OK,TRUE},
             {"?:word@winehq.org/",S_OK,TRUE},
             {"ftp://test?:word@winehq.org/",S_OK,FALSE},
@@ -988,7 +988,7 @@ static const uri_properties uri_tests[] = {
             {"#:word@winehq.org/",S_OK,TRUE},
             {"test",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://test#:word@winehq.org/",S_OK,FALSE},
@@ -1018,7 +1018,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"winehq.org",S_OK,FALSE},
             {"word",S_OK,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://test\\:word@winehq.org/",S_OK,FALSE},
@@ -1048,7 +1048,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"127.0.0.100",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://127.000.000.100/",S_OK,FALSE},
@@ -1078,7 +1078,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"127.0.0.0",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://127.0/",S_OK,FALSE},
@@ -1108,7 +1108,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"0.1.226.64",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://123456/",S_OK,FALSE},
@@ -1138,7 +1138,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"255.255.255.255",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://4294967295/",S_OK,FALSE},
@@ -1168,7 +1168,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"4294967296",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://4294967296/",S_OK,FALSE},
@@ -1198,7 +1198,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"4294967295",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"1234://4294967295/",S_OK,FALSE},
@@ -1228,7 +1228,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"127.001",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"1234://127.001/",S_OK,FALSE},
@@ -1257,7 +1257,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"fedc:ba98::3210",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[FEDC:BA98::3210]",S_OK,FALSE},
@@ -1286,7 +1286,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"::",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[::]",S_OK,FALSE},
@@ -1315,7 +1315,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"fedc:ba98::",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[FEDC:BA98::]",S_OK,FALSE},
@@ -1345,7 +1345,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"1:0:3:4:5:6:7:8",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[1::3:4:5:6:7:8]",S_OK,FALSE},
@@ -1374,7 +1374,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"[v2.34]",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[v2.34]/",S_OK,FALSE},
@@ -1404,7 +1404,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"[xyz:12345.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test",S_OK,TRUE},
+            {"/test",S_OK,FALSE},
             {"/test",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[xyz:12345.com/test",S_OK,FALSE},
@@ -1436,7 +1436,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.[works].com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"ftp://www.[works].com/",S_OK,FALSE},
@@ -1466,7 +1466,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.google.com]",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://www.google.com]:12345/",S_OK,FALSE},
@@ -1496,7 +1496,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"w%XXw%GEw.google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://w%XXw%GEw.google.com/",S_OK,FALSE},
@@ -1526,7 +1526,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"GOOGLE.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://GOOGLE.com/",S_OK,FALSE},
@@ -1556,7 +1556,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://WWW.GOOGLE.com/",S_OK,FALSE},
@@ -1588,7 +1588,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.%7cgoogle%7c.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://www.%7Cgoogle|.com/",S_OK,FALSE},
@@ -1618,7 +1618,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"1:2:3:4:5:6::",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[1:2:3:4:5:6:0.0.0.0]",S_OK,FALSE},
@@ -1648,7 +1648,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"::1.2.3.0",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[::001.002.003.000]",S_OK,FALSE},
@@ -1678,7 +1678,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"0001:0:000:0004:0005:0006:001.002.003.000",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://[0001:0:000:0004:0005:0006:001.002.003.000]",S_OK,FALSE},
@@ -1708,7 +1708,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"ffff::c0de:6f20",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[ffff::192.222.111.32]",S_OK,FALSE},
@@ -1738,7 +1738,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.com:65535",S_OK,FALSE},
@@ -1767,7 +1767,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com:65536",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://google.com:65536",S_OK,FALSE},
@@ -1796,7 +1796,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com:65536:25",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://google.com:65536:25",S_OK,FALSE},
@@ -1825,7 +1825,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"[::ffff]:abcd",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://[::ffff]:abcd",S_OK,FALSE},
@@ -1854,7 +1854,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"127.0.0.1:abcd",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://127.0.0.1:abcd",S_OK,FALSE},
@@ -1883,7 +1883,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"",S_FALSE,TRUE},
+            {"",S_FALSE,FALSE},
             {"",S_FALSE,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.com:00035",S_OK,FALSE},
@@ -1912,7 +1912,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"",S_FALSE,TRUE},
+            {"",S_FALSE,FALSE},
             {"",S_FALSE,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.com:80",S_OK,FALSE},
@@ -1941,7 +1941,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.com.uk",S_OK,FALSE},
@@ -1970,7 +1970,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.com.com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.com.com",S_OK,FALSE},
@@ -1999,7 +1999,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.uk.1",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.uk.1",S_OK,FALSE},
@@ -2029,7 +2029,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"google.foo.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://google.foo.uk",S_OK,FALSE},
@@ -2058,7 +2058,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {".com",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://.com",S_OK,FALSE},
@@ -2087,7 +2087,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {".uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://.uk",S_OK,FALSE},
@@ -2116,7 +2116,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.co.google.com.[]",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://www.co.google.com.[]",S_OK,FALSE},
@@ -2145,7 +2145,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"co.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://co.uk",S_OK,FALSE},
@@ -2174,7 +2174,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.co.google.us.test",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://www.co.google.us.test",S_OK,FALSE},
@@ -2203,7 +2203,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk",S_OK,FALSE},
@@ -2231,7 +2231,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"www.google.com\\test",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"",S_FALSE,TRUE},
+            {"",S_FALSE,FALSE},
             {"",S_FALSE,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://www.google.com\\test",S_OK,FALSE},
@@ -2259,7 +2259,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"excepts:bad:%XY:encoded",S_OK,TRUE},
+            {"excepts:bad:%XY:encoded",S_OK,FALSE},
             {"excepts:bad:%XY:encoded",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"urn:excepts:bad:%XY:encoded",S_OK,FALSE},
@@ -2290,7 +2290,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/C:/te%253Es%252Et/tes%25t.mp3",S_OK,TRUE},
+            {"/C:/te%253Es%252Et/tes%25t.mp3",S_OK,FALSE},
             {"/C:/te%253Es%252Et/tes%25t.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"file://C:/te%3Es%2Et/tes%t.mp3",S_OK,FALSE},
@@ -2321,7 +2321,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/C:/te%3Es.t/t#es%25t.mp3",S_OK,TRUE},
+            {"/C:/te%3Es.t/t#es%25t.mp3",S_OK,FALSE},
             {"/C:/te%3Es.t/t#es%25t.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"file:///C:/te%3Es%2Et/t%23es%t.mp3",S_OK,FALSE},
@@ -2351,7 +2351,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"::1.2.3.0",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/%3F%23.T/test",S_OK,TRUE},
+            {"/%3F%23.T/test",S_OK,FALSE},
             {"/%3F%23.T/test",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://[::001.002.003.000]/%3F%23%2E%54/test",S_OK,FALSE},
@@ -2380,7 +2380,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/C:/%22test%22/test.mp3",S_OK,TRUE},
+            {"/C:/%22test%22/test.mp3",S_OK,FALSE},
             {"/C:/%22test%22/test.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"file:///C:/\"test\"/test.mp3",S_OK,FALSE},
@@ -2410,7 +2410,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"4294967295",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/<|>\" test<|>",S_OK,TRUE},
+            {"/<|>\" test<|>",S_OK,FALSE},
             {"/<|>\" test<|>",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"1234://4294967295/<|>\" test<|>",S_OK,FALSE},
@@ -2440,7 +2440,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/%3C%7C%3E%20test%3C%7C%3E",S_OK,TRUE},
+            {"/%3C%7C%3E%20test%3C%7C%3E",S_OK,FALSE},
             {"/%3C%7C%3E%20test%3C%7C%3E",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk/<|> test<|>",S_OK,FALSE},
@@ -2469,7 +2469,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk/test/../test2/././../test3/.././././",S_OK,FALSE},
@@ -2498,7 +2498,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk/test/test2/../../..",S_OK,FALSE},
@@ -2527,7 +2527,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk/test/test2/../../.",S_OK,FALSE},
@@ -2555,7 +2555,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"/c:/foo%2520bar.mp3",S_OK,TRUE},
+            {"/c:/foo%2520bar.mp3",S_OK,FALSE},
             {"/c:/foo%2520bar.mp3",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"file://c:\\tests\\../tests\\./.\\..\\foo%20bar.mp3",S_OK,FALSE},
@@ -2585,7 +2585,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/",S_OK,TRUE},
+            {"/",S_OK,FALSE},
             {"/",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"zip://gov.uk/test/test2/../../.",S_OK,FALSE},
@@ -2615,7 +2615,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test/test2/../../.",S_OK,TRUE},
+            {"/test/test2/../../.",S_OK,FALSE},
             {"/test/test2/../../.",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"http://gov.uk/test/test2/../../.",S_OK,FALSE},
@@ -2645,7 +2645,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"gov.uk",S_OK,FALSE},
             {"",S_FALSE,FALSE},
-            {"/test/test2/../../.",S_OK,TRUE},
+            {"/test/test2/../../.",S_OK,FALSE},
             {"/test/test2/../../.",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"*:gov.uk/test/test2/../../.",S_OK,FALSE},
@@ -2674,7 +2674,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"%22acco%3C%7C%3Eunt@example.com%22",S_OK,TRUE},
+            {"%22acco%3C%7C%3Eunt@example.com%22",S_OK,FALSE},
             {"%22acco%3C%7C%3Eunt@example.com%22",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"mailto:\"acco<|>unt@example.com\"",S_OK,FALSE},
@@ -2702,7 +2702,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.tes%3C%7C%3Et.com",S_OK,TRUE},
+            {"test.tes%3C%7C%3Et.com",S_OK,FALSE},
             {"test.tes%3C%7C%3Et.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"news:test.tes<|>t.com",S_OK,FALSE},
@@ -2731,7 +2731,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.tes<|>t.com",S_OK,TRUE},
+            {"test.tes<|>t.com",S_OK,FALSE},
             {"test.tes<|>t.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"news:test.tes<|>t.com",S_OK,FALSE},
@@ -2760,7 +2760,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.tes<|>t.com",S_OK,TRUE},
+            {"test.tes<|>t.com",S_OK,FALSE},
             {"test.tes<|>t.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"urn:test.tes<|>t.com",S_OK,FALSE},
@@ -2789,7 +2789,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.test.com",S_OK,TRUE},
+            {"test.test.com",S_OK,FALSE},
             {"test.test.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"news:test.%74%65%73%74.com",S_OK,FALSE},
@@ -2818,7 +2818,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.test.com",S_OK,TRUE},
+            {"test.test.com",S_OK,FALSE},
             {"test.test.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"news:test.%74%65%73%74.com",S_OK,FALSE},
@@ -2847,7 +2847,7 @@ static const uri_properties uri_tests[] = {
             {"",S_FALSE,TRUE},
             {"",S_FALSE,FALSE},
             {"",S_FALSE,FALSE},
-            {"test.%74%65%73%74.com",S_OK,TRUE},
+            {"test.%74%65%73%74.com",S_OK,FALSE},
             {"test.%74%65%73%74.com",S_OK,TRUE},
             {"",S_FALSE,TRUE},
             {"urn:test.%74%65%73%74.com",S_OK,FALSE},
diff --git a/dlls/urlmon/uri.c b/dlls/urlmon/uri.c
index f5ca037c450..07e99449d61 100644
--- a/dlls/urlmon/uri.c
+++ b/dlls/urlmon/uri.c
@@ -2848,6 +2848,19 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST
         if(!(*pbstrProperty))
             return E_OUTOFMEMORY;
 
+        break;
+    case Uri_PROPERTY_PATH:
+        if(This->path_start > -1) {
+            *pbstrProperty = SysAllocStringLen(This->canon_uri+This->path_start, This->path_len);
+            hres = S_OK;
+        } else {
+            *pbstrProperty = SysAllocStringLen(NULL, 0);
+            hres = S_FALSE;
+        }
+
+        if(!(*pbstrProperty))
+            hres = E_OUTOFMEMORY;
+
         break;
     case Uri_PROPERTY_RAW_URI:
         *pbstrProperty = SysAllocString(This->raw_uri);
@@ -2956,6 +2969,10 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D
         *pcchProperty = (This->userinfo_split > -1) ? This->userinfo_len-This->userinfo_split-1 : 0;
         hres = (This->userinfo_split > -1) ? S_OK : S_FALSE;
         break;
+    case Uri_PROPERTY_PATH:
+        *pcchProperty = This->path_len;
+        hres = (This->path_start > -1) ? S_OK : S_FALSE;
+        break;
     case Uri_PROPERTY_RAW_URI:
         *pcchProperty = SysStringLen(This->raw_uri);
         hres = S_OK;
@@ -3113,13 +3130,8 @@ static HRESULT WINAPI Uri_GetPassword(IUri *iface, BSTR *pstrPassword)
 
 static HRESULT WINAPI Uri_GetPath(IUri *iface, BSTR *pstrPath)
 {
-    Uri *This = URI_THIS(iface);
-    FIXME("(%p)->(%p)\n", This, pstrPath);
-
-    if(!pstrPath)
-        return E_POINTER;
-
-    return E_NOTIMPL;
+    TRACE("(%p)->(%p)\n", iface, pstrPath);
+    return Uri_GetPropertyBSTR(iface, Uri_PROPERTY_PATH, pstrPath, 0);
 }
 
 static HRESULT WINAPI Uri_GetPathAndQuery(IUri *iface, BSTR *pstrPathAndQuery)
-- 
GitLab