Closed
Bug 1306033
Opened 8 years ago
Closed 8 years ago
NS_ENSURE_SUCCESS(rv, rv) failed with NS_ERROR_NOT_AVAILABLE: file netwerk/cache2/CacheEntry.cpp, line 1151
Categories
(Core :: Networking: Cache, defect)
Core
Networking: Cache
Tracking
()
RESOLVED
FIXED
mozilla52
Tracking | Status | |
---|---|---|
firefox52 | --- | fixed |
People
(Reporter: nbp, Assigned: mayhemer)
References
Details
(Whiteboard: [necko-active])
Attachments
(1 file, 1 obsolete file)
3.27 KB,
patch
|
michal
:
review+
|
Details | Diff | Splinter Review |
Every time the alternate data is not available, NS_ENSURE_SUCCESS produces a warning. This would produce warnings for every load where an alternative data type is preferred, for the first visit and for any script where we are unable to produce alternate data for. I suggest to manually filter out NS_ERROR_NOT_AVAILABLE before calling NS_ENSURE_SUCCESS.
Reporter | ||
Comment 1•8 years ago
|
||
As unavailable alternate data type is a common, expected, and supported case, we should not produce a warning for such issues. This patch filters out the unavailable error before the use of NS_ENSURE_SUCCESS macro.
Attachment #8795773 -
Flags: review?(valentin.gosu)
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → nicolas.b.pierron
Whiteboard: [necko-active]
Comment 2•8 years ago
|
||
Comment on attachment 8795773 [details] [diff] [review] Explicitly filter out unavailable alternate data type errors. Review of attachment 8795773 [details] [diff] [review]: ----------------------------------------------------------------- Honza, is this OK, or are we better off replacing NS_ENSURE with if (NS_FAILED(rv)) return rv?
Attachment #8795773 -
Flags: review?(valentin.gosu) → review?(honzab.moz)
Assignee | ||
Updated•8 years ago
|
Attachment #8795773 -
Flags: review?(honzab.moz)
Assignee | ||
Comment 3•8 years ago
|
||
Failure of call to CacheEntry::OpenAlternativeInputStream with NS_ERROR_NOT_AVAILABLE is legal. The patch as suggested deletes warnings that we may want to log. I will take this bug and have a patch that should preserve console warnings in some cases that might be useful to have.
Assignee: nicolas.b.pierron → honzab.moz
Status: NEW → ASSIGNED
Assignee | ||
Comment 4•8 years ago
|
||
Michal, this is what I think is worth to spit to the console, but feel free to suggest changes.
Attachment #8795773 -
Attachment is obsolete: true
Attachment #8796180 -
Flags: review?(michal.novotny)
Updated•8 years ago
|
Attachment #8796180 -
Flags: review?(michal.novotny) → review+
Assignee | ||
Comment 5•8 years ago
|
||
(no need for a try run, this only changes few warning prints to the console)
Keywords: checkin-needed
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/06cb6118fd79 Only fatal console warnings on failures of OpenAlternativeInputStream in HTTP cache. r=michal
Keywords: checkin-needed
Comment 7•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/06cb6118fd79
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox52:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
You need to log in
before you can comment on or make changes to this bug.
Description
•