New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 788965 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug



Sign in to add a comment

Mojo binding being rebound in content::DeviceSensorEventPump<blink::WebDeviceOrientationListener>::SensorEntry::OnSensorCreated

Project Member Reported by jamwalla@chromium.org, Nov 28 2017

Issue description

On tip of tree, chrome and webview crash when a youtube video is the first url opened. The check that fails is https://cs.chromium.org/chromium/src/mojo/public/cpp/bindings/lib/binding_state.cc?l=90

Steps to reproduce:
(1) Open chrome or webview browser shell
(2) paste and navigate to https://m.youtube.com/watch?v=ZJDMWVZta3M

The video should be the first page opened; I can't reproduce this by opening m.youtube.com and then opening a video.

Stack trace attached.
 
stack.txt
41.5 KB View Download

Comment 1 by boliu@chromium.org, Nov 29 2017

Cc: roc...@chromium.org
cc rockot, could someone on mojo take a look. fairly easy to reproduce on chrome on android

Comment 2 by roc...@chromium.org, Nov 29 2017

Cc: blundell@chromium.org
Someone who worked on device sensor code should take a look. I don't recall who did that though.

Comment 3 by roc...@chromium.org, Nov 29 2017

This DCHECK indicates a mojo consumer is using a binding type incorrectly, by trying to bind and already-bound binding.

Comment 4 by boliu@chromium.org, Nov 29 2017

Cc: reillyg@chromium.org juncai@chromium.org
cc some folks who touched device_sensor_event_pump.h last..
Cc: -juncai@chromium.org
Components: -Internals>Mojo>Bindings Blink>Sensor>DeviceOrientation
Labels: -Pri-3 M-64 Pri-1
Owner: juncai@chromium.org
Status: Started (was: Untriaged)
Summary: Mojo binding being rebound in content::DeviceSensorEventPump<blink::WebDeviceOrientationListener>::SensorEntry::OnSensorCreated (was: DCHECK(!router_) fails in BindingStateBase::BindInternal)
juncai@ can reproduce this and is taking a look.
Cc: juncai@chromium.org
 Issue 798409  has been merged into this issue.
Project Member

Comment 8 by bugdroid1@chromium.org, Jan 11 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5d2543a1086ba586a9d142caedf8fb4ef3739fb6

commit 5d2543a1086ba586a9d142caedf8fb4ef3739fb6
Author: Jun Cai <juncai@chromium.org>
Date: Thu Jan 11 20:07:32 2018

Add SensorState to make sure SensorEntry::sensor only binds once

This CL adds a sensor state machine to make sure during the sensor
initialization, sensor is only created once.

Here is the design doc which explains the change in this CL:
https://docs.google.com/document/d/1eA2YjNVcTIMPdJhA4sxv1qaksdW507SNb2Jfsij_G_U/edit

Bug:  788965 
Change-Id: Id20c745377b1320281dce72f097792c5b478cc38
Reviewed-on: https://chromium-review.googlesource.com/798595
Reviewed-by: Nasko Oskov <nasko@chromium.org>
Reviewed-by: Reilly Grant <reillyg@chromium.org>
Commit-Queue: Jun Cai <juncai@chromium.org>
Cr-Commit-Position: refs/heads/master@{#528724}
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_motion_event_pump.cc
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_motion_event_pump.h
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_motion_event_pump_unittest.cc
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_orientation_event_pump.cc
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_orientation_event_pump.h
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_orientation_event_pump_unittest.cc
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/device_sensor_event_pump.h
[add] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/fake_sensor_and_provider.cc
[add] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/renderer/device_sensors/fake_sensor_and_provider.h
[modify] https://crrev.com/5d2543a1086ba586a9d142caedf8fb4ef3739fb6/content/test/BUILD.gn

Comment 9 by juncai@chromium.org, Jan 11 2018

Status: Fixed (was: Started)

Sign in to add a comment