Closed
Bug 1195951
Opened 9 years ago
Closed 9 years ago
MediaStreamError contains Heap<T> and is allocated on the stack
Categories
(Core :: JavaScript: GC, defect)
Core
JavaScript: GC
Tracking
()
RESOLVED
FIXED
mozilla43
Tracking | Status | |
---|---|---|
firefox43 | --- | fixed |
People
(Reporter: nika, Assigned: jib)
References
Details
Attachments
(1 file)
dom/media/systemservices/MediaUtils.h:125:15: error: variable of type 'mozilla::dom::MediaStreamError' only valid on the heap void Reject(ErrorType rv) ^ dom/media/systemservices/MediaUtils.h:125:15: note: value incorrectly allocated in an automatic variable ../../../dist/include/mozilla/dom/MediaStreamError.h:59:7: note: 'mozilla::dom::MediaStreamError' is a heap type because it inherits from a heap type 'nsWrapperCache' class MediaStreamError final : public nsISupports, ^ ../../../dist/include/nsWrapperCache.h:352:23: note: 'nsWrapperCache' is a heap type because member 'mWrapper' is a heap type 'JS::Heap<JSObject *>' JS::Heap<JSObject*> mWrapper; ^ 1 error generated.
Comment 1•9 years ago
|
||
(In reply to Michael Layzell [:mystor] from comment #0) > dom/media/systemservices/MediaUtils.h:125:15: error: variable of type > 'mozilla::dom::MediaStreamError' only valid on the heap > void Reject(ErrorType rv) I'm not familiar with this code, but I doesn't see how the Reject method is going to work. It takes an ErrorType template argument and assigns it to an nsRefPtr<ErrorType>, and is used with ErrorType as dom::MediaStreamError in the MediaManager class: typedef media::Pledge<SourceSet*, dom::MediaStreamError> PledgeSourceSet; Maybe it should take an nsRefPtr<ErrorType>? But I don't really know what's going on here. Looks like this was added in bug 1173255. jib, do you know how this works?
Flags: needinfo?(jib)
Assignee | ||
Comment 2•9 years ago
|
||
Bug 1195951 - fix heap type on stack error in MediaUtils' Pledge class
Attachment #8663420 -
Flags: review?(rjesup)
Assignee | ||
Comment 3•9 years ago
|
||
This should work better.
Comment 4•9 years ago
|
||
Comment on attachment 8663420 [details] MozReview Request: Bug 1195951 - fix heap type on stack error in MediaUtils' Pledge class https://reviewboard.mozilla.org/r/19793/#review17769
Attachment #8663420 -
Flags: review?(rjesup) → review+
Assignee | ||
Updated•9 years ago
|
Keywords: checkin-needed
Assignee | ||
Comment 5•9 years ago
|
||
Included in this green try - https://treeherder.mozilla.org/#/jobs?repo=try&revision=a2069a0548b0
Comment 7•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/564f9c049d15
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox43:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
You need to log in
before you can comment on or make changes to this bug.
Description
•