mirror of
https://gitlab.freedesktop.org/libfprint/libfprint.git
synced 2025-11-15 07:38:12 +00:00
image-device: Set cancelling when errors are reported
Allow the AWAIT_FINGER_ON to deactivation state transition after errors are reported.
This commit is contained in:
@@ -419,7 +419,9 @@ fpi_image_device_retry_scan (FpImageDevice *self, FpDeviceRetry retry)
|
|||||||
/* We abort the operation and let the surrounding code retry in the
|
/* We abort the operation and let the surrounding code retry in the
|
||||||
* non-enroll case (this is identical to a session error). */
|
* non-enroll case (this is identical to a session error). */
|
||||||
g_debug ("Abort current operation due to retry (non-enroll case)");
|
g_debug ("Abort current operation due to retry (non-enroll case)");
|
||||||
|
priv->cancelling = TRUE;
|
||||||
fpi_image_device_deactivate (self);
|
fpi_image_device_deactivate (self);
|
||||||
|
priv->cancelling = FALSE;
|
||||||
fpi_device_action_error (FP_DEVICE (self), error);
|
fpi_device_action_error (FP_DEVICE (self), error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -467,7 +469,9 @@ fpi_image_device_session_error (FpImageDevice *self, GError *error)
|
|||||||
if (error->domain == FP_DEVICE_RETRY)
|
if (error->domain == FP_DEVICE_RETRY)
|
||||||
g_warning ("Driver should report retries using fpi_image_device_retry_scan!");
|
g_warning ("Driver should report retries using fpi_image_device_retry_scan!");
|
||||||
|
|
||||||
|
priv->cancelling = TRUE;
|
||||||
fpi_image_device_deactivate (self);
|
fpi_image_device_deactivate (self);
|
||||||
|
priv->cancelling = FALSE;
|
||||||
fpi_device_action_error (FP_DEVICE (self), error);
|
fpi_device_action_error (FP_DEVICE (self), error);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user