Commit 7dac81dc authored by Marco Trevisan's avatar Marco Trevisan
Browse files

device: Use g_clear_error instead of doing the same manually

We've now an utility function that can help us to free and unset an error
double pointer, so let's use it.
parent 1ecae1d0
......@@ -476,8 +476,7 @@ _fprint_device_check_polkit_for_actions (FprintDevice *rdev,
if (_fprint_device_check_polkit_for_action (rdev, context, action1, error) != FALSE)
return TRUE;
g_error_free (*error);
*error = NULL;
g_clear_error (error);
return _fprint_device_check_polkit_for_action (rdev, context, action2, error);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment