Fix possible crash without a deactivate callback
We were checking for ->activate existing instead of ->deactivate.
This commit is contained in:
parent
c96fa32da4
commit
3d2e545264
1 changed files with 1 additions and 1 deletions
|
@ -370,7 +370,7 @@ static void dev_deactivate(struct fp_img_dev *imgdev)
|
||||||
struct fp_driver *drv = imgdev->dev->drv;
|
struct fp_driver *drv = imgdev->dev->drv;
|
||||||
struct fp_img_driver *imgdrv = fpi_driver_to_img_driver(drv);
|
struct fp_img_driver *imgdrv = fpi_driver_to_img_driver(drv);
|
||||||
|
|
||||||
if (!imgdrv->activate)
|
if (!imgdrv->deactivate)
|
||||||
return;
|
return;
|
||||||
return imgdrv->deactivate(imgdev);
|
return imgdrv->deactivate(imgdev);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue