Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
cfc0f97d
Commit
cfc0f97d
authored
Jun 24, 2010
by
Thomas Mullaly
Committed by
Alexandre Julliard
Jul 23, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
urlmon: Partially implemented IUri_GetHost.
parent
6a1dd3d1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
14 deletions
+37
-14
uri.c
dlls/urlmon/tests/uri.c
+7
-7
uri.c
dlls/urlmon/uri.c
+30
-7
No files found.
dlls/urlmon/tests/uri.c
View file @
cfc0f97d
...
...
@@ -329,7 +329,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
".txt"
,
S_OK
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"127.0.0.1"
,
S_OK
,
TRU
E
},
{
"127.0.0.1"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/test%20dir/test.txt"
,
S_OK
,
TRUE
},
{
"/test%20dir/test.txt"
,
S_OK
,
TRUE
},
...
...
@@ -1233,7 +1233,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"127.0.0.100"
,
S_OK
,
TRU
E
},
{
"127.0.0.100"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
@@ -1263,7 +1263,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"127.0.0.0"
,
S_OK
,
TRU
E
},
{
"127.0.0.0"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
@@ -1293,7 +1293,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"0.1.226.64"
,
S_OK
,
TRU
E
},
{
"0.1.226.64"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
@@ -1323,7 +1323,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"255.255.255.255"
,
S_OK
,
TRU
E
},
{
"255.255.255.255"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
@@ -1383,7 +1383,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"4294967295"
,
S_OK
,
TRU
E
},
{
"4294967295"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
@@ -1413,7 +1413,7 @@ static const uri_properties uri_tests[] = {
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
""
,
S_FALSE
,
TRUE
},
{
"127.001"
,
S_OK
,
TRU
E
},
{
"127.001"
,
S_OK
,
FALS
E
},
{
""
,
S_FALSE
,
FALSE
},
{
"/"
,
S_OK
,
TRUE
},
{
"/"
,
S_OK
,
TRUE
},
...
...
dlls/urlmon/uri.c
View file @
cfc0f97d
...
...
@@ -1241,6 +1241,22 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST
}
switch
(
uriProp
)
{
case
Uri_PROPERTY_HOST
:
if
(
This
->
host_start
>
-
1
)
{
*
pbstrProperty
=
SysAllocStringLen
(
This
->
canon_uri
+
This
->
host_start
,
This
->
host_len
);
hres
=
S_OK
;
}
else
{
/* Canonicalizing/parsing the host of a URI is only partially
* implemented, so return E_NOTIMPL for now.
*/
FIXME
(
"(%p)->(%d %p %x) Partially implemented
\n
"
,
This
,
uriProp
,
pbstrProperty
,
dwFlags
);
return
E_NOTIMPL
;
}
if
(
!
(
*
pbstrProperty
))
hres
=
E_OUTOFMEMORY
;
break
;
case
Uri_PROPERTY_PASSWORD
:
if
(
This
->
userinfo_split
>
-
1
)
{
*
pbstrProperty
=
SysAllocStringLen
(
...
...
@@ -1338,6 +1354,18 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D
}
switch
(
uriProp
)
{
case
Uri_PROPERTY_HOST
:
if
(
This
->
host_start
==
-
1
)
{
/* Canonicalizing/parsing the host of a URI is only partially
* implemented, so return E_NOTIMPL for now.
*/
FIXME
(
"(%p)->(%d %p %x) Partially implemented
\n
"
,
This
,
uriProp
,
pcchProperty
,
dwFlags
);
return
E_NOTIMPL
;
}
*
pcchProperty
=
This
->
host_len
;
hres
=
(
This
->
host_start
>
-
1
)
?
S_OK
:
S_FALSE
;
break
;
case
Uri_PROPERTY_PASSWORD
:
*
pcchProperty
=
(
This
->
userinfo_split
>
-
1
)
?
This
->
userinfo_len
-
This
->
userinfo_split
-
1
:
0
;
hres
=
(
This
->
userinfo_split
>
-
1
)
?
S_OK
:
S_FALSE
;
...
...
@@ -1483,13 +1511,8 @@ static HRESULT WINAPI Uri_GetFragment(IUri *iface, BSTR *pstrFragment)
static
HRESULT
WINAPI
Uri_GetHost
(
IUri
*
iface
,
BSTR
*
pstrHost
)
{
Uri
*
This
=
URI_THIS
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pstrHost
);
if
(
!
pstrHost
)
return
E_POINTER
;
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%p)
\n
"
,
iface
,
pstrHost
);
return
Uri_GetPropertyBSTR
(
iface
,
Uri_PROPERTY_HOST
,
pstrHost
,
0
);
}
static
HRESULT
WINAPI
Uri_GetPassword
(
IUri
*
iface
,
BSTR
*
pstrPassword
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment