Closed Bug 1420334 Opened 7 years ago Closed 7 years ago

Intermittent any test PROCESS-CRASH | application crashed [@ mozilla::TimeStamp::operator-(mozilla::TimeStamp const &)] after Assertion failure: !aOther.IsNull() (Cannot compute with aOther null value)

Categories

(Core :: Networking: Cache, defect, P3)

defect

Tracking

()

RESOLVED FIXED
mozilla59
Tracking Status
firefox-esr52 --- unaffected
firefox57 --- unaffected
firefox58 --- unaffected
firefox59 --- fixed

People

(Reporter: intermittent-bug-filer, Assigned: CuveeHsu)

References

Details

(Keywords: crash, intermittent-failure, Whiteboard: [necko-triaged][stockwell fixed:product])

Crash Data

Attachments

(1 file, 1 obsolete file)

OnStartRequest is in the main thread, but OnCacheEntryCheck depends on the open thread.
Sometimes we encounter race condition in mOnStartRequestTimestamp.

Since this is only for telemetry, I'd like to add a null-check here instead of lock.
Assignee: nobody → juhsu
Still suffer from no Atomic<mozilla::TimeStamp>.
Consider to use Atmoic<PRTime>.
Depends on: 1354407
Priority: P5 → P3
Whiteboard: [necko-triaged]
(In reply to Junior[:junior] from comment #4)
> OnStartRequest is in the main thread, but OnCacheEntryCheck depends on the
> open thread.
> Sometimes we encounter race condition in mOnStartRequestTimestamp.
> 
> Since this is only for telemetry, I'd like to add a null-check here instead
> of lock.

We already use mRCWNLock in nsHttpChannel::OnCacheEntryCheck, so why not to simply grab the lock at https://searchfox.org/mozilla-central/rev/7a8c667bdd2a4a32746c9862356e199627c0896d/netwerk/protocol/http/nsHttpChannel.cpp#6945 ?
Flags: needinfo?(juhsu)
Since lock is not free.
However, we can lock only if the network wins.

Thanks michal!
Flags: needinfo?(juhsu)
Comment on attachment 8933208 [details] [diff] [review]
lockTimestamp, v1

Review of attachment 8933208 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good. Maybe add a comment explaining why the lock is needed.
Attachment #8933208 - Flags: review?(michal.novotny) → review+
add comment and carry r+
Attachment #8933208 - Attachment is obsolete: true
Attachment #8933538 - Flags: review+
Keywords: checkin-needed
Pushed by rgurzau@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1f6112300d6e
protect timestamp setting in a critical section, r=michal
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/1f6112300d6e
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Whiteboard: [necko-triaged][stockwell needswork:owner] → [necko-triaged][stockwell fixed:product]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: