New issue
Advanced search Search tips

Issue 844190 link

Starred by 2 users

Issue metadata

Status: Untriaged
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

More sender-side DCHECKing for mojom validation

Project Member Reported by roc...@chromium.org, May 17 2018

Issue description

Validation failures can sometimes be subtle in their presentation (a somewhat cryptic log message) and it's not always evident who the offending sender is.

For some failure modes -- like sending a null handle for a non-nullable handle field -- we do DCHECKing within the sender during serialization. We should do more of this, because it makes locating bad code much easier.

Example things we could DCHECK/assert in serialization that we don't today:

- enum value checks
- invalid union tags
- anything in Java bindings

It's not clear that we have a good option for JS bindings that wouldn't bloat the code, but maybe at least in development builds (is_dcheck_on) we could generate extra assertions in the JS.
 

Sign in to add a comment