Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
dd61c795
Commit
dd61c795
authored
Nov 23, 2011
by
Jacek Caban
Committed by
Alexandre Julliard
Nov 23, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Use IUri for IHTMLLocation::get_hostname implementation.
parent
3fe5e6ee
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
10 deletions
+12
-10
htmllocation.c
dlls/mshtml/htmllocation.c
+12
-10
No files found.
dlls/mshtml/htmllocation.c
View file @
dd61c795
...
...
@@ -359,7 +359,7 @@ static HRESULT WINAPI HTMLLocation_put_hostname(IHTMLLocation *iface, BSTR v)
static
HRESULT
WINAPI
HTMLLocation_get_hostname
(
IHTMLLocation
*
iface
,
BSTR
*
p
)
{
HTMLLocation
*
This
=
impl_from_IHTMLLocation
(
iface
);
URL_COMPONENTSW
url
=
{
sizeof
(
URL_COMPONENTSW
)}
;
BSTR
hostname
;
HRESULT
hres
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
...
...
@@ -367,19 +367,21 @@ static HRESULT WINAPI HTMLLocation_get_hostname(IHTMLLocation *iface, BSTR *p)
if
(
!
p
)
return
E_POINTER
;
url
.
dwHostNameLength
=
1
;
hres
=
get_url_components
(
This
,
&
url
);
if
(
FAILED
(
hres
))
return
hres
;
if
(
!
This
->
window
||
!
This
->
window
->
uri
)
{
FIXME
(
"No current URI
\n
"
);
return
E_NOTIMPL
;
}
if
(
!
url
.
dwHostNameLength
){
hres
=
IUri_GetHost
(
This
->
window
->
uri
,
&
hostname
);
if
(
hres
==
S_OK
)
{
*
p
=
hostname
;
}
else
if
(
hres
==
S_FALSE
)
{
SysFreeString
(
hostname
);
*
p
=
NULL
;
return
S_OK
;
}
else
{
return
hres
;
}
*
p
=
SysAllocStringLen
(
url
.
lpszHostName
,
url
.
dwHostNameLength
);
if
(
!*
p
)
return
E_OUTOFMEMORY
;
return
S_OK
;
}
...
...
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