Closed
Bug 448476
Opened 17 years ago
Closed 17 years ago
Make mozIStorageConnection threadsafe
Categories
(Core :: SQLite and Embedded Database Bindings, defect)
Core
SQLite and Embedded Database Bindings
Tracking
()
RESOLVED
FIXED
mozilla1.9.1a2
People
(Reporter: sdwilsh, Assigned: sdwilsh)
References
Details
Attachments
(1 file, 1 obsolete file)
13.96 KB,
patch
|
robarnold
:
review+
|
Details | Diff | Splinter Review |
People need to use it on more than one thread.
Assignee | ||
Comment 1•17 years ago
|
||
Pretty simple :)
Attachment #331805 -
Flags: review?(bent.mozilla)
Assignee | ||
Updated•17 years ago
|
Whiteboard: [has patch][needs review bent]
Shawn, I won't be able to get to this until next week.
Assignee | ||
Comment 3•17 years ago
|
||
Comment on attachment 331805 [details] [diff] [review]
v1.0
Let's try myk then
Attachment #331805 -
Flags: review?(bent.mozilla) → review?(myk)
Comment 4•17 years ago
|
||
Comment on attachment 331805 [details] [diff] [review]
v1.0
Unfortunately, I'm not qualified to review this, not being familiar with the facility being used to ensure thread safety.
Attachment #331805 -
Flags: review?(myk)
Assignee | ||
Comment 5•17 years ago
|
||
Comment on attachment 331805 [details] [diff] [review]
v1.0
switching to robarnold - I'll have bent look at it post landing just to make sure of things.
Attachment #331805 -
Flags: review?(tellrob)
Assignee | ||
Updated•17 years ago
|
Whiteboard: [has patch][needs review bent] → [has patch][needs review robarnold]
Comment 6•17 years ago
|
||
Comment on attachment 331805 [details] [diff] [review]
v1.0
You need to document what each mutex guards
Does Close need a lock around its "if(mProgressHandler)" block?
In SetProgressHandler, shouldn't the lock be acquired before *aOldHandler = mProgressHandler? aOldHandler may not be what the caller expects. ReleaseProgressHandler seems to do this correctly.
Assignee | ||
Comment 7•17 years ago
|
||
(In reply to comment #6)
> Does Close need a lock around its "if(mProgressHandler)" block?
Reads should be atomic, but I think it's not a bad idea to do that to be safe
> In SetProgressHandler, shouldn't the lock be acquired before *aOldHandler =
> mProgressHandler? aOldHandler may not be what the caller expects.
Yeah, I think you are right there as well.
Assignee | ||
Comment 8•17 years ago
|
||
I'm not documenting the mutexes because given their names and where they are declared in the header file (directly above the variables in question, with white space grouping them with said variable), I think it would be redundant, and excessive documentation isn't needed (nor wanted).
Attachment #331805 -
Attachment is obsolete: true
Attachment #333128 -
Flags: review?(tellrob)
Attachment #331805 -
Flags: review?(tellrob)
Updated•17 years ago
|
Attachment #333128 -
Flags: review?(tellrob) → review+
Assignee | ||
Updated•17 years ago
|
Whiteboard: [has patch][needs review robarnold] → [has patch][has review][can land]
Comment 9•17 years ago
|
||
Pushed to mozilla-central:
http://hg.mozilla.org/mozilla-central/index.cgi/rev/66ab9c4075c4
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Updated•17 years ago
|
Whiteboard: [has patch][has review][can land]
Assignee | ||
Updated•17 years ago
|
Flags: in-testsuite-
Flags: in-litmus-
Updated•1 year ago
|
Product: Toolkit → Core
You need to log in
before you can comment on or make changes to this bug.
Description
•