Open Bug 137946 Opened 23 years ago Updated 2 years ago

Reloading POST submission silently fails if file is deleted

Categories

(Core :: DOM: Navigation, defect)

x86
All
defect

Tracking

()

Future

People

(Reporter: john, Unassigned)

References

(Depends on 1 open bug)

Details

Reloading a POST submission causes submission to silently fail. It should give the user feedback as to why. This probably can be extended more generally to other errors that may occur in POST submission. Steps: 1. submit a file in a POST operation. 2. delete that file. 3. reload the POST operation. Expected Result: Some kind of feedback is given to the user as to why the submission cannot continue. Actual Result: Submission does not continue and no feedback is given to the user as to why. Stems from discussion on and about bug 126829. The relevant code is in nsDocShell, where it checks the return value of Seek(0). That is the call that will fail if any of the files that were submitted get removed.
-> docshell component
Assignee: darin → adamlock
Component: Networking: HTTP → Embedding: Docshell
QA Contact: tever → adamlock
In fact, wouldn't it make sense to report _all_ errors from LoadURI? For example, in bug 77850 we have a malformed data: uri... that causes NS_NewChannel to fail and the error return is ignored, so clicking on that link just silently does nothing....
A failed call to DoURILoad is followed by a call to DisplayLoadError. If nsISeekableStream::Seek returned a meaningful error, e.g. file doesn't exist any more, it should be straightforward to add logic to the error function to display an appropriate error message. From inspection of the code, it doesn't appear to do this. I could assume in DoURILoad to return NS_ERROR_FILE_NOT_FOUND when Seek failed, but as I don't know if the postdata is a file or something else such as string buffer it wouldn't be very meaningful.
Target Milestone: --- → Future
adam: let's fix the implementation of Seek to return the right error code.
Assignee: adamlock → nobody
QA Contact: adamlock → docshell
Depends on: 425891
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.