Closed
Bug 302115
Opened 19 years ago
Closed 19 years ago
"Try again" on XUL error page loads wrong thing after going back
Categories
(Core :: DOM: Navigation, defect, P1)
Core
DOM: Navigation
Tracking
()
VERIFIED
FIXED
mozilla1.8beta4
People
(Reporter: MatsPalmgren_bugz, Assigned: Biesinger)
References
()
Details
(Whiteboard: [ETA 8/6])
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
bzbarsky
:
approval-branch-1.8.1-
|
Details | Diff | Splinter Review |
"Try again" on "Net Timeout Error" page loads wrong URL STEPS TO REPRODUCE 1. make a request for http://1.2.3.4/ and wait for it to timeout... (the "Net Timeout Error" page is presented.) 2. make a request that will succeed, e.g. http://www.mozilla.org/ 3. go Back and wait for it to timeout again 4. click on "Try again" ACTUAL RESULTS The URL entered in step 2 loads EXPECTED RESULTS The URL entered in step 1 should be requested again, ideally without killing forward history. PLATFORMS & BUILDS TESTED SeaMonkey nightly build 2005-07-23-01 trunk Linux (100% reproducible)
Reporter | ||
Comment 2•19 years ago
|
||
The bug also occurs with user_pref("browser.sessionhistory.max_entries", 0); user_pref("browser.sessionhistory.max_viewers", 0);
Comment 3•19 years ago
|
||
I see the same on WinXP. Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b4) Gecko/20050725 Firefox/1.0+ ID:2005072521
WFM with Mozilla 1.8b1 (XUL error pages enabled) but reproducible with Deer Park a2.
Comment 5•19 years ago
|
||
The trunk XUL error page is a re-write, or at least a rearrangement. The "Try again" button doesn't explicitly load the error URL (although we know it), we do a location.reload() instead (according to the code comments this is in case there's postdata). If you go back from some page to an error page the "try again" button loads the page you came back from. The odd thing is that location.href shows the intended URL, but location.reload() does something else anyway. But only for error pages; in the regular case after a back reload does refresh the page you're on. turning off bfcache (assuming browser.sessionhistory.max_viewers=0 is off) made no difference.
Assignee: adamlock → benjamin
Flags: blocking1.8b4?
Flags: blocking-aviary1.5+
Summary: "Try again" on "Net Timeout Error" page loads wrong URL → "Try again" on XUL error page loads wrong thing after going back
Updated•19 years ago
|
Flags: blocking1.8b4? → blocking1.8b4-
Priority: -- → P2
Assignee | ||
Comment 6•19 years ago
|
||
also fails with DNS errors; changing URL, as those are faster to test ;)
Assignee | ||
Comment 8•19 years ago
|
||
ok, mOSHE is wrong and mLSHE is null. I assume SH remembers a load type of ERROR_PAGE which makes InternalLoad not set mLSHE...
Assignee | ||
Updated•19 years ago
|
Whiteboard: [ETA 8/6]
Assignee | ||
Comment 9•19 years ago
|
||
sigh, I was wrong... there is no mLSHE created for shistory traversal, so mOSHE never gets a new value...
Assignee | ||
Comment 10•19 years ago
|
||
I hate docshell.
Attachment #191703 -
Flags: superreview?(darin)
Attachment #191703 -
Flags: review?(bryner)
Assignee | ||
Updated•19 years ago
|
Status: NEW → ASSIGNED
OS: Linux → All
Hardware: PC → All
Target Milestone: --- → mozilla1.8beta4
Comment 11•19 years ago
|
||
(In reply to comment #9) > sigh, I was wrong... there is no mLSHE created for shistory traversal, so mOSHE > never gets a new value... Hm, I'm not sure what you mean here.... are you referring to traversal via bfcache? We do set mLSHE in that case now (we didn't used to).
Assignee | ||
Comment 12•19 years ago
|
||
It's more complex than that... the thing is, EndPageLoad clears mLSHE, assuming that something set mOSHE earlier. Usually, Embed seems to do that. But in this case, the load resulted in an error, so Embed wasn't called. So mLSHE is cleared. LoadErrorPage is then called, and it tries to set an mLSHE by calling OnNewURI, but because this is a history load, it does not create a sh entry. To work around that, I get the sh entry from the shistory object in this patch.
Assignee | ||
Comment 13•19 years ago
|
||
now, there's two things I noticed, namely: - location.reload() and the reload toolbar button act differently (iirc one acts on mOSHE, the other gets the entry from the shistory) - mOSHE and mLSHE really seem redundant and could maybe be replaced with always getting the entry from the nsISHistory object
Comment 14•19 years ago
|
||
bryner has a patch in the works to make mOSHE and the nsISHistory always match, I believe.
Comment 15•19 years ago
|
||
My patch (which landed) is more to cover the case where we navigate between session history clones. It doesn't do anything for this case.
Assignee | ||
Updated•19 years ago
|
Attachment #191703 -
Flags: superreview?(darin) → superreview?(bzbarsky)
Updated•19 years ago
|
Attachment #191703 -
Flags: superreview?(bzbarsky) → superreview+
Updated•19 years ago
|
Flags: blocking-aviary1.5+
Comment 17•19 years ago
|
||
Comment on attachment 191703 [details] [diff] [review] patch Looks ok, maybe comment in particular on why mLSHE might be null.
Attachment #191703 -
Flags: review?(bryner) → review+
Assignee | ||
Comment 18•19 years ago
|
||
with comment added.
Attachment #191703 -
Attachment is obsolete: true
Assignee | ||
Comment 19•19 years ago
|
||
Checking in docshell/base/nsDocShell.cpp; /cvsroot/mozilla/docshell/base/nsDocShell.cpp,v <-- nsDocShell.cpp new revision: 1.771; previous revision: 1.770 done Checking in docshell/shistory/public/nsISHistory.idl; /cvsroot/mozilla/docshell/shistory/public/nsISHistory.idl,v <-- nsISHistory.idl new revision: 1.15; previous revision: 1.14 done Checking in docshell/shistory/src/nsSHistory.cpp; /cvsroot/mozilla/docshell/shistory/src/nsSHistory.cpp,v <-- nsSHistory.cpp new revision: 1.77; previous revision: 1.76 done
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 20•19 years ago
|
||
Comment on attachment 212390 [details] [diff] [review] merged to trunk I think we should take this on the branch too.
Attachment #212390 -
Flags: approval-branch-1.8.1?(bzbarsky)
Assignee | ||
Comment 21•19 years ago
|
||
hm, actually, the first attachment is the right one for the branch (shistory wasn't moved to docshell/ there)
Comment 22•19 years ago
|
||
Comment on attachment 212390 [details] [diff] [review] merged to trunk Can't change interfaces on the branch. :(
Attachment #212390 -
Flags: approval-branch-1.8.1?(bzbarsky) → approval-branch-1.8.1-
Comment 23•19 years ago
|
||
As in, if we want this on branch we need to have a branch-only interface or something.
Comment 26•17 years ago
|
||
Verified with Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4; en-US; rv:1.9b5pre) Gecko/2008031804 Minefield/3.0b5pre ID:2008031804
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•