android: camera_hal_manager: Stop thread when destroying
The CameraHalManager starts a thread that is never stopped. This leads to the thread being destroyed while running, which causes a crash. Fix this by stopping the thread and waiting for it to finish in the destructor of the CameraHalManager. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
@@ -24,6 +24,8 @@ class CameraProxy;
|
||||
class CameraHalManager : public libcamera::Thread
|
||||
{
|
||||
public:
|
||||
~CameraHalManager();
|
||||
|
||||
int init();
|
||||
|
||||
CameraProxy *open(unsigned int id, const hw_module_t *module);
|
||||
|
||||
Reference in New Issue
Block a user