commit | 0bb5e09f253dd9b9e578a332d64ad9fe90b1f83d | [log] [tgz] |
---|---|---|
author | Jan Sebechlebsky <jsebechlebsky@google.com> | Fri Dec 08 16:17:54 2023 +0100 |
committer | Jan Sebechlebsky <jsebechlebsky@google.com> | Fri Dec 08 19:29:41 2023 +0100 |
tree | 8c033e5ac9280a89941ada0ce13222a29b2a3fbf | |
parent | fd378c3b7b665f24f1e4487189f447e7384a0809 [diff] |
Fix crash when virtual camera is unregistered during active session. Store weak_ptr to VirtualCameraDevice instance in VirtualCameraSession to detect when the camera was removed as well as to make sure it's not destroyed when VirtualCameraSession accesses VirtualCameraDevice. Bug: 301023410 Test: atest VirtualCameraTest (not closing the session) Test: atest virtual_camera_tests Change-Id: Ie87c91f6872b9241dddf64f1a4f1991eb54d3cda