mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1245264, r=bz
MozReview-Commit-ID: I0sVdritpD3
This commit is contained in:
parent
935278501a
commit
b7e3eeb362
@ -696,6 +696,16 @@ nsLocation::SetProtocol(const nsAString& aProtocol)
|
||||
if (NS_WARN_IF(NS_FAILED(rv))) {
|
||||
return rv;
|
||||
}
|
||||
nsAutoCString newSpec;
|
||||
rv = uri->GetSpec(newSpec);
|
||||
if (NS_FAILED(rv)) {
|
||||
return rv;
|
||||
}
|
||||
// We may want a new URI class for the new URI, so recreate it:
|
||||
rv = NS_NewURI(getter_AddRefs(uri), newSpec);
|
||||
if (NS_FAILED(rv)) {
|
||||
return rv;
|
||||
}
|
||||
|
||||
return SetURI(uri);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user