Closed
Bug 1132934
Opened 10 years ago
Closed 6 years ago
Consider preventing accidental calls to XPCOM methods from bindings code
Categories
(Core :: DOM: Core & HTML, defect, P3)
Tracking
()
RESOLVED
FIXED
People
(Reporter: bzbarsky, Assigned: bzbarsky)
References
(Depends on 1 open bug, Blocks 1 open bug)
Details
Attachments
(1 file, 14 obsolete files)
Consider this IDL
interface Foo {
attribute boolean bar;
};
and this implementation class:
class Foo {
bool Bar();
NS_IMETHOD SetBar(bool arg);
};
Currently this compiles just fine and silently ignores the return value of SetBar. This causes problems like bug 1132347 where we ignore errors from functions we should really care about.
This bug is about maybe preventing that. I say maybe because a bunch of HTML element things explicily have bindings call XPCOM setters that are known to not fail... and because the signatures for an attribute setter that takes a string are actually identical for bindings and XPCOM, which means the only way to disambiguate is by renaming one or the other.
Assignee | ||
Comment 1•10 years ago
|
||
I guess in fact that all the cases this would catch have identical signatures, so we'd need to rename a bunch of things that are in fact infallible. Maybe that's ok.
Assignee | ||
Comment 2•7 years ago
|
||
MozReview-Commit-ID: A20gseUzUFT
Attachment #8948087 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Assignee: nobody → bzbarsky
Status: NEW → ASSIGNED
Assignee | ||
Comment 3•7 years ago
|
||
MozReview-Commit-ID: L1ILcLGAyy
Attachment #8948088 -
Flags: review?(nika)
Assignee | ||
Comment 4•7 years ago
|
||
MozReview-Commit-ID: Csqh40GjqJn
Attachment #8948089 -
Flags: review?(nika)
Assignee | ||
Comment 5•7 years ago
|
||
MozReview-Commit-ID: C15Gr1oxq8s
Attachment #8948090 -
Flags: review?(nika)
Assignee | ||
Comment 6•7 years ago
|
||
MozReview-Commit-ID: 47Pc4Puub4T
Attachment #8948091 -
Flags: review?(nika)
Assignee | ||
Comment 7•7 years ago
|
||
MozReview-Commit-ID: EmoJDwDw4kp
Attachment #8948092 -
Flags: review?(nika)
Assignee | ||
Comment 8•7 years ago
|
||
MozReview-Commit-ID: 8cf2jHkGS7L
Attachment #8948093 -
Flags: review?(nika)
Assignee | ||
Comment 9•7 years ago
|
||
MozReview-Commit-ID: 3qsXzmoqQlY
Attachment #8948094 -
Flags: review?(nika)
Assignee | ||
Comment 10•7 years ago
|
||
MozReview-Commit-ID: PCHylPszxI
Attachment #8948095 -
Flags: review?(nika)
Assignee | ||
Comment 11•7 years ago
|
||
MozReview-Commit-ID: JBdem9vRgcN
Attachment #8948096 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948087 -
Attachment is obsolete: true
Attachment #8948087 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948096 -
Attachment is obsolete: true
Attachment #8948096 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948095 -
Attachment is obsolete: true
Attachment #8948095 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948094 -
Attachment is obsolete: true
Attachment #8948094 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948093 -
Attachment is obsolete: true
Attachment #8948093 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948092 -
Attachment is obsolete: true
Attachment #8948092 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948091 -
Attachment is obsolete: true
Attachment #8948091 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948090 -
Attachment is obsolete: true
Attachment #8948090 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948089 -
Attachment is obsolete: true
Attachment #8948089 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Attachment #8948088 -
Attachment is obsolete: true
Attachment #8948088 -
Flags: review?(nika)
Assignee | ||
Comment 12•7 years ago
|
||
Comment 13•7 years ago
|
||
Pushed by bzbarsky@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1023e033bfa6
part 1. Actually propagate out exceptions from the innerHTML getter. r=smaug
Assignee | ||
Updated•7 years ago
|
Keywords: leave-open
Assignee | ||
Comment 14•7 years ago
|
||
MozReview-Commit-ID: KEqsx836qQn
Attachment #8962502 -
Flags: review?(bugs)
Comment 15•7 years ago
|
||
Backout by bzbarsky@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/463447801c4c
Backed out changeset 1023e033bfa6 because it hasn't been reviewed yet.
Comment 16•7 years ago
|
||
Comment on attachment 8962502 [details] [diff] [review]
Actually propagate out exceptions from the innerHTML getter
I guess we could improve GetMarkup to throw OOM, if needed, in the future.
Attachment #8962502 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 17•7 years ago
|
||
Comment on attachment 8962502 [details] [diff] [review]
Actually propagate out exceptions from the innerHTML getter
This was not meant to go on this bug... and it should be using GetterCanOOM anyway.
Attachment #8962502 -
Attachment is obsolete: true
Attachment #8962502 -
Flags: review+
Updated•7 years ago
|
Priority: -- → P3
Assignee | ||
Comment 18•6 years ago
|
||
There are no JS implementations that I can see, but this will get us nicer bisectability if it turns out I'm wrong.
Attachment #8983164 -
Flags: review?(dtownsend)
Assignee | ||
Comment 19•6 years ago
|
||
Attachment #8983165 -
Flags: review?(dtownsend)
Assignee | ||
Updated•6 years ago
|
Attachment #8983164 -
Attachment is obsolete: true
Attachment #8983164 -
Flags: review?(dtownsend)
Assignee | ||
Updated•6 years ago
|
Attachment #8983165 -
Attachment is obsolete: true
Attachment #8983165 -
Flags: review?(dtownsend)
Assignee | ||
Comment 20•6 years ago
|
||
MozReview-Commit-ID: 7kJ3CqB9fCN
Attachment #9012457 -
Flags: review?(bugs)
Assignee | ||
Updated•6 years ago
|
Attachment #8957787 -
Attachment is obsolete: true
Updated•6 years ago
|
Attachment #9012457 -
Flags: review?(bugs) → review+
Comment 21•6 years ago
|
||
Pushed by bzbarsky@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/596f7ad9ff29
Make Web IDL bindings enforce that void methods they call (including setters) actually have void as a return type. r=smaug
Comment 22•6 years ago
|
||
bugherder |
Assignee | ||
Updated•6 years ago
|
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•