Note: There are a few cases of duplicates in user autocompletion which are being worked on.

IO on the main thread caused by nsDiskCacheOutputStream::Close()

RESOLVED FIXED in mozilla12

Status

()

Core
Networking: Cache
--
major
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: michal, Assigned: michal)

Tracking

Trunk
mozilla12
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

6 years ago
nsDiskCacheOutputStream::Close() is called on the main thread if all nsInputStreamTeeWriteEvent events finish before nsStreamListenerTee::OnStartRequest() is called.
(Assignee)

Comment 1

6 years ago
Created attachment 586742 [details] [diff] [review]
fix - release sink on the same thread where the data is written
Attachment #586742 - Flags: review?(bjarne)

Comment 2

6 years ago
Comment on attachment 586742 [details] [diff] [review]
fix - release sink on the same thread where the data is written

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

Looks reasonable - does it pass tryserver? Is there a way we can have a test for this?

Please re-request review after addressing the above questions.

::: netwerk/base/src/nsStreamListenerTee.cpp
@@ +67,5 @@
>      if (mInputTee) {
>          mInputTee->SetSink(nsnull);
>          mInputTee = 0;
>      }
> +

Nit: Please add a comment including the bug-number.
Attachment #586742 - Flags: review?(bjarne)
(Assignee)

Comment 3

6 years ago
Created attachment 587008 [details] [diff] [review]
patch v2 - added a comment

(In reply to Bjarne (:bjarne) from comment #2)
> Looks reasonable - does it pass tryserver?

No, it doesn't. But tryserver is useless these days.

result with patch: https://tbpl.mozilla.org/?tree=Try&rev=96d185e8731e
result without it: https://tbpl.mozilla.org/?tree=Try&rev=bd7e5b7b5ea3


> Is there a way we can have a test for this?

I don't see a way how to test it.
Attachment #586742 - Attachment is obsolete: true
Attachment #587008 - Flags: review?(bjarne)

Comment 4

6 years ago
Comment on attachment 587008 [details] [diff] [review]
patch v2 - added a comment

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

Code looks ok. Would be more happy if it passed try and/or had a test, but fair enough...
Attachment #587008 - Flags: review?(bjarne) → review+
(Assignee)

Comment 5

6 years ago
http://hg.mozilla.org/integration/mozilla-inbound/rev/dc23947abad9
Whiteboard: [inbound]
Target Milestone: --- → mozilla12
https://hg.mozilla.org/mozilla-central/rev/dc23947abad9
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Whiteboard: [inbound]
You need to log in before you can comment on or make changes to this bug.