sms-mbim: fix peek_device to use g_task_report_new_error
When porting MMSmsMbim to use GTask, peek_device wasn't modified to use g_task_report_new_error, which could potentially lead to an incorrect G_TASK cast.
This commit is contained in:

committed by
Aleksander Morgado

parent
d25e6bdfaa
commit
ce664a6264
@@ -53,12 +53,13 @@ peek_device (gpointer self,
|
|||||||
|
|
||||||
port = mm_base_modem_peek_port_mbim (modem);
|
port = mm_base_modem_peek_port_mbim (modem);
|
||||||
if (!port) {
|
if (!port) {
|
||||||
g_simple_async_report_error_in_idle (G_OBJECT (self),
|
g_task_report_new_error (self,
|
||||||
callback,
|
callback,
|
||||||
user_data,
|
user_data,
|
||||||
MM_CORE_ERROR,
|
peek_device,
|
||||||
MM_CORE_ERROR_FAILED,
|
MM_CORE_ERROR,
|
||||||
"Couldn't peek MBIM port");
|
MM_CORE_ERROR_FAILED,
|
||||||
|
"Couldn't peek MBIM port");
|
||||||
g_object_unref (modem);
|
g_object_unref (modem);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user