Closed
Bug 1186750
Opened 9 years ago
Closed 9 years ago
Clean up smart pointer usage of device storage events
Categories
(Core :: DOM: Device Interfaces, defect)
Core
DOM: Device Interfaces
Tracking
()
RESOLVED
FIXED
mozilla45
People
(Reporter: xidorn, Assigned: xidorn)
References
(Blocks 1 open bug)
Details
Attachments
(7 files, 8 obsolete files)
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
40 bytes,
text/x-review-board-request
|
dhylands
:
review+
|
Details |
When working on bug 1184729, I noticed that the device storage part has some smart pointer usages on event dispatch which need non-trivial fix, which I'm going to fix first.
Assignee | ||
Comment 1•9 years ago
|
||
Bug 1186750 part 1 - Inlinize trivial constructors and destructors of events in DeviceStorageRequestParent.
Attachment #8637840 -
Flags: review?(dhylands)
Assignee | ||
Comment 2•9 years ago
|
||
Bug 1186750 part 2 - Remove some unused member fields in events in DeviceStorageRequestParent.
Attachment #8637841 -
Flags: review?(dhylands)
Assignee | ||
Comment 3•9 years ago
|
||
Bug 1186750 part 3 - Abstract CancelableFileEvent in DeviceStorageReqeustParent and use already_AddRefed&& for passing DeviceStorageFile parameter.
Attachment #8637842 -
Flags: review?(dhylands)
Assignee | ||
Comment 4•9 years ago
|
||
Bug 1186750 part 4 - Clear runnable list in DeviceStorageRequestParent when being destroyed.
Attachment #8637843 -
Flags: review?(dhylands)
Assignee | ||
Comment 5•9 years ago
|
||
Bug 1186750 part 5 - Convert DeviceStorageUsedSpaceCache::Dispatch to use already_AddRef&&.
Attachment #8637844 -
Flags: review?(dhylands)
Assignee | ||
Comment 6•9 years ago
|
||
Bug 1186750 part 6 - Use already_AddRefed&& to initialize most smart pointer fields of device storage events.
Attachment #8637845 -
Flags: review?(dhylands)
Assignee | ||
Comment 7•9 years ago
|
||
Bug 1186750 part 7 - Simplify code in DeviceStorageRequestParent::Dispatch.
Attachment #8637846 -
Flags: review?(dhylands)
Assignee | ||
Comment 8•9 years ago
|
||
Bug 1186750 part 8 - Convert all usage of Dispatch/NS_DispatchTo{Main,Current}Thread in dom/devicestorage to pass in either already_AddRefed or raw pointer.
Attachment #8637847 -
Flags: review?(dhylands)
Assignee | ||
Comment 9•9 years ago
|
||
Try push looks good: https://treeherder.mozilla.org/#/jobs?repo=try&revision=247d0664351d
Updated•9 years ago
|
Attachment #8637840 -
Flags: review?(dhylands) → review+
Comment 10•9 years ago
|
||
Comment on attachment 8637840 [details] MozReview Request: Bug 1186750 part 1 - Inlinize trivial constructors and destructors of events in DeviceStorageRequestParent. https://reviewboard.mozilla.org/r/13981/#review12567 Ship It!
Comment 11•9 years ago
|
||
Comment on attachment 8637841 [details] MozReview Request: Bug 1186750 part 2 - Remove some unused member fields in events in DeviceStorageRequestParent. https://reviewboard.mozilla.org/r/13983/#review12571 Ship It!
Attachment #8637841 -
Flags: review?(dhylands) → review+
Updated•9 years ago
|
Attachment #8637842 -
Flags: review?(dhylands) → review+
Comment 12•9 years ago
|
||
Comment on attachment 8637842 [details] MozReview Request: Bug 1186750 part 3 - Abstract CancelableFileEvent in DeviceStorageReqeustParent and use already_AddRefed&& for passing DeviceStorageFile parameter. https://reviewboard.mozilla.org/r/13985/#review12577 Ship It!
Comment 13•9 years ago
|
||
Comment on attachment 8637843 [details] MozReview Request: Bug 1186750 part 4 - Clear runnable list in DeviceStorageRequestParent when being destroyed. https://reviewboard.mozilla.org/r/13987/#review12579 Learning lots of C++11 features here :)
Attachment #8637843 -
Flags: review?(dhylands) → review+
Comment 14•9 years ago
|
||
Comment on attachment 8637844 [details] MozReview Request: Bug 1186750 part 5 - Convert DeviceStorageUsedSpaceCache::Dispatch to use already_AddRef&&. https://reviewboard.mozilla.org/r/13989/#review12581 Ship It!
Attachment #8637844 -
Flags: review?(dhylands) → review+
Comment 15•9 years ago
|
||
Comment on attachment 8637845 [details] MozReview Request: Bug 1186750 part 6 - Use already_AddRefed&& to initialize most smart pointer fields of device storage events. https://reviewboard.mozilla.org/r/13991/#review12583 Ship It!
Attachment #8637845 -
Flags: review?(dhylands) → review+
Comment 16•9 years ago
|
||
Comment on attachment 8637846 [details] MozReview Request: Bug 1186750 part 7 - Simplify code in DeviceStorageRequestParent::Dispatch. https://reviewboard.mozilla.org/r/13993/#review12585 Ship It!
Attachment #8637846 -
Flags: review?(dhylands) → review+
Updated•9 years ago
|
Attachment #8637847 -
Flags: review?(dhylands) → review+
Comment 17•9 years ago
|
||
Comment on attachment 8637847 [details] MozReview Request: Bug 1186750 part 8 - Convert all usage of Dispatch/NS_DispatchTo{Main,Current}Thread in dom/devicestorage to pass in either already_AddRefed or raw pointer. https://reviewboard.mozilla.org/r/13995/#review12587 Ship It!
Comment 18•9 years ago
|
||
P.S. - thanks for splitting the patches up the way you. This made it super easy to review.
Comment hidden (obsolete) |
Assignee | ||
Comment 20•9 years ago
|
||
Sorry for the delay. It took a long time to land bug 1186745, and then I was stuck in some other things. It seems there was some significant change during this period, and patch 5~8 are no longer able to be applied cleanly. (And it also seems all NS_DispatchToCurrentThread uses were removed.) I'm going to land patch 1~4 soon (which are mostly trivial changes) and request review for the rest of patches. Sorry again for wasting your time reviewing patches which were not landed.
Assignee | ||
Comment 21•9 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=b55060845159
Assignee | ||
Comment 22•9 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=03771f854ff0
Assignee | ||
Comment 23•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/e0a9cf2fb44acff1bdeb8852997de649546c0a1f Bug 1186750 part 1 - Inlinize trivial constructors and destructors of events in DeviceStorageRequestParent. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/ef5f9a2a41a47d4f61ee7c8c5fcce6ea5784ed39 Bug 1186750 part 2 - Remove some unused member fields in events in DeviceStorageRequestParent. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/5add786777f33f60445a5658ba9e3459e7eec84a Bug 1186750 part 3 - Abstract CancelableFileEvent in DeviceStorageReqeustParent and use already_AddRefed&& for passing DeviceStorageFile parameter. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/fa9922692623cea44fb2fb29064e24380372aafb Bug 1186750 part 4 - Clear runnable list in DeviceStorageRequestParent when being destroyed. r=dhylands
Assignee | ||
Updated•9 years ago
|
Keywords: leave-open
Assignee | ||
Updated•9 years ago
|
Attachment #8637840 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637841 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637842 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637843 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637844 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637845 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637846 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8637847 -
Attachment is obsolete: true
Assignee | ||
Comment 24•9 years ago
|
||
Bug 1186750 part 5 - Convert nsDOMDeviceStorage::CheckPermission to take already_AddRefed&&.
Attachment #8689441 -
Flags: review?(dhylands)
Assignee | ||
Comment 25•9 years ago
|
||
Bug 1186750 part 6 - Remove unused and unimplemented method nsDOMDeviceStorage::StorePermission.
Attachment #8689442 -
Flags: review?(dhylands)
Assignee | ||
Comment 26•9 years ago
|
||
Bug 1186750 part 7 - Convert DispatchToOwningThread and DispatchOrAbandon to take already_AddRefed&&.
Attachment #8689443 -
Flags: review?(dhylands)
Assignee | ||
Comment 27•9 years ago
|
||
Bug 1186750 part 8 - Convert DeviceStorageUsedSpaceCache::Dispatch to use already_AddRef&&.
Attachment #8689444 -
Flags: review?(dhylands)
Assignee | ||
Comment 28•9 years ago
|
||
Bug 1186750 part 9 - Use already_AddRefed&& to initialize mFile of device storage requests.
Attachment #8689445 -
Flags: review?(dhylands)
Assignee | ||
Comment 29•9 years ago
|
||
Bug 1186750 part 10 - Simplify code in DeviceStorageRequestParent::Dispatch.
Attachment #8689446 -
Flags: review?(dhylands)
Assignee | ||
Comment 30•9 years ago
|
||
Bug 1186750 part 11 - Convert all usage of Dispatch/NS_DispatchToMainThread in dom/devicestorage to pass in either already_AddRefed or raw pointer.
Attachment #8689447 -
Flags: review?(dhylands)
Assignee | ||
Comment 31•9 years ago
|
||
Part 10 seems to be identical to the old part 7, so you probably can r+ directly.
Comment 32•9 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/e0a9cf2fb44a https://hg.mozilla.org/mozilla-central/rev/ef5f9a2a41a4 https://hg.mozilla.org/mozilla-central/rev/5add786777f3 https://hg.mozilla.org/mozilla-central/rev/fa9922692623
Comment 33•9 years ago
|
||
Comment on attachment 8689441 [details] MozReview Request: Bug 1186750 part 5 - Convert nsDOMDeviceStorage::CheckPermission to take already_AddRefed&&. https://reviewboard.mozilla.org/r/25635/#review23155
Attachment #8689441 -
Flags: review?(dhylands) → review+
Updated•9 years ago
|
Attachment #8689442 -
Flags: review?(dhylands) → review+
Comment 34•9 years ago
|
||
Comment on attachment 8689442 [details] MozReview Request: Bug 1186750 part 6 - Remove unused and unimplemented method nsDOMDeviceStorage::StorePermission. https://reviewboard.mozilla.org/r/25637/#review23157
Comment 35•9 years ago
|
||
Comment on attachment 8689443 [details] MozReview Request: Bug 1186750 part 7 - Convert DispatchToOwningThread and DispatchOrAbandon to take already_AddRefed&&. https://reviewboard.mozilla.org/r/25639/#review23159
Attachment #8689443 -
Flags: review?(dhylands) → review+
Comment 36•9 years ago
|
||
Comment on attachment 8689444 [details] MozReview Request: Bug 1186750 part 8 - Convert DeviceStorageUsedSpaceCache::Dispatch to use already_AddRef&&. https://reviewboard.mozilla.org/r/25641/#review23161
Attachment #8689444 -
Flags: review?(dhylands) → review+
Comment 37•9 years ago
|
||
Comment on attachment 8689445 [details] MozReview Request: Bug 1186750 part 9 - Use already_AddRefed&& to initialize mFile of device storage requests. https://reviewboard.mozilla.org/r/25643/#review23163
Attachment #8689445 -
Flags: review?(dhylands) → review+
Comment 38•9 years ago
|
||
Comment on attachment 8689446 [details] MozReview Request: Bug 1186750 part 10 - Simplify code in DeviceStorageRequestParent::Dispatch. https://reviewboard.mozilla.org/r/25645/#review23165
Attachment #8689446 -
Flags: review?(dhylands) → review+
Comment 39•9 years ago
|
||
Comment on attachment 8689447 [details] MozReview Request: Bug 1186750 part 11 - Convert all usage of Dispatch/NS_DispatchToMainThread in dom/devicestorage to pass in either already_AddRefed or raw pointer. https://reviewboard.mozilla.org/r/25647/#review23153 r=me if you address the XPCOM_NO_SMARTPOINTER_DISPATCH define. I couldn't see any reason for it to be defined. ::: dom/devicestorage/moz.build:52 (Diff revision 1) > +CXXFLAGS += ['-DXPCOM_NO_SMARTPOINTER_DISPATCH'] What does this do? I couldn't find any references to this in the codebase.
Attachment #8689447 -
Flags: review?(dhylands) → review+
Assignee | ||
Comment 40•9 years ago
|
||
(In reply to Dave Hylands [:dhylands] from comment #39) > Comment on attachment 8689447 [details] > MozReview Request: Bug 1186750 part 11 - Convert all usage of > Dispatch/NS_DispatchToMainThread in dom/devicestorage to pass in either > already_AddRefed or raw pointer. > > https://reviewboard.mozilla.org/r/25647/#review23153 > > r=me if you address the XPCOM_NO_SMARTPOINTER_DISPATCH define. I couldn't > see any reason for it to be defined. > > ::: dom/devicestorage/moz.build:52 > (Diff revision 1) > > +CXXFLAGS += ['-DXPCOM_NO_SMARTPOINTER_DISPATCH'] > > What does this do? I couldn't find any references to this in the codebase. It is something I want to introduce in bug 1226073. Since that bug gets stuck, I'm going to land this patchset without this line. Thanks for the fast reviewing.
Assignee | ||
Comment 41•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/bd192633b5e49db4b88e31ffd11157be6d446ae8 Bug 1186750 part 5 - Convert nsDOMDeviceStorage::CheckPermission to take already_AddRefed&&. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/dc63519e3cae242606a1009f707af3d0f6943344 Bug 1186750 part 6 - Remove unused and unimplemented method nsDOMDeviceStorage::StorePermission. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/cbd3f6d49362e867b8e9e9bdfea3a18c970d3a6b Bug 1186750 part 7 - Convert DispatchToOwningThread and DispatchOrAbandon to take already_AddRefed&&. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/ebb8a91b830ab636683df1aa684f002caef9438e Bug 1186750 part 8 - Convert DeviceStorageUsedSpaceCache::Dispatch to use already_AddRef&&. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/c5aa32cc038f734fe2b41caced968fb15a692405 Bug 1186750 part 9 - Use already_AddRefed&& to initialize mFile of device storage requests. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/0fb7145a9eecf6e26a33217fa665ad5b6b330258 Bug 1186750 part 10 - Simplify code in DeviceStorageRequestParent::Dispatch. r=dhylands https://hg.mozilla.org/integration/mozilla-inbound/rev/41db68696ad0434455ac585e522be98e43a119d3 Bug 1186750 part 11 - Convert all usage of Dispatch/NS_DispatchToMainThread in dom/devicestorage to pass in either already_AddRefed or raw pointer. r=dhylands
Assignee | ||
Updated•9 years ago
|
Keywords: leave-open
Comment 42•9 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/bd192633b5e4 https://hg.mozilla.org/mozilla-central/rev/dc63519e3cae https://hg.mozilla.org/mozilla-central/rev/cbd3f6d49362 https://hg.mozilla.org/mozilla-central/rev/ebb8a91b830a https://hg.mozilla.org/mozilla-central/rev/c5aa32cc038f https://hg.mozilla.org/mozilla-central/rev/0fb7145a9eec https://hg.mozilla.org/mozilla-central/rev/41db68696ad0
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox45:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
You need to log in
before you can comment on or make changes to this bug.
Description
•