mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
bug #102774 (r=jst@netscape.com, sr=vidur@netscape.com). location.reload(true) did not cause the cache to be bypassed.
This commit is contained in:
parent
5950ddf5e7
commit
e4def3f5bb
@ -699,13 +699,23 @@ LocationImpl::SetSearch(const nsAReadableString& aSearch)
|
||||
NS_IMETHODIMP
|
||||
LocationImpl::Reload(PRBool aForceget)
|
||||
{
|
||||
nsresult rv;
|
||||
nsCOMPtr<nsIWebNavigation> webNav(do_QueryInterface(mDocShell));
|
||||
NS_ENSURE_TRUE(webNav, NS_ERROR_FAILURE);
|
||||
|
||||
NS_ENSURE_SUCCESS(webNav->Reload(nsIWebNavigation::LOAD_FLAGS_NONE),
|
||||
NS_ERROR_FAILURE);
|
||||
if (webNav) {
|
||||
PRUint32 reloadFlags = nsIWebNavigation::LOAD_FLAGS_NONE;
|
||||
|
||||
return NS_OK;
|
||||
if (aForceget) {
|
||||
reloadFlags = nsIWebNavigation::LOAD_FLAGS_BYPASS_CACHE |
|
||||
nsIWebNavigation::LOAD_FLAGS_BYPASS_PROXY;
|
||||
}
|
||||
rv = webNav->Reload(reloadFlags);
|
||||
} else {
|
||||
NS_ASSERTION(0, "nsIWebNavigation interface is not available!");
|
||||
rv = NS_ERROR_FAILURE;
|
||||
}
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
|
Loading…
Reference in New Issue
Block a user