Closed
Bug 1204834
Opened 10 years ago
Closed 10 years ago
OS.File.writeAtomic should take care to keep the path argument alive
Categories
(Toolkit Graveyard :: OS.File, defect)
Toolkit Graveyard
OS.File
Tracking
(firefox43 fixed)
RESOLVED
FIXED
mozilla43
Tracking | Status | |
---|---|---|
firefox43 | --- | fixed |
People
(Reporter: gfritzsche, Assigned: gfritzsche, Mentored)
References
(Blocks 1 open bug)
Details
(Whiteboard: [lang=js][good first bug])
Attachments
(1 file)
1.23 KB,
patch
|
Yoric
:
review+
|
Details | Diff | Splinter Review |
writeAtomic keeps the arguments it posts to its worker alive with a closure:
https://dxr.mozilla.org/mozilla-central/rev/29b2df16e961fbe9a379362ecba6f888d1754bc3/toolkit/components/osfile/modules/osfile_async_front.jsm#1178
However, it doesn't keep |path| alive there, possibly leading to races.
Comment 1•10 years ago
|
||
Actually, I don't think that a race is possible here, at least if `path` is a string.
Anyway, fixing this bug should be quite easy. In function `writeAtomic`, linked above, we just need to add argument `path` to the second array.
Mentor: dteller
Component: Async Tooling → OS.File
Whiteboard: [lang=js][good first bug]
Assignee | ||
Comment 2•10 years ago
|
||
Updated•10 years ago
|
Attachment #8661155 -
Flags: review?(dteller) → review+
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
Updated•2 years ago
|
Product: Toolkit → Toolkit Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•