[PATCH] anydata: remove unused 'port' field in DetailedRegistrationStateContext

Aleksander Morgado aleksander at aleksander.es
Sat Oct 7 08:03:01 UTC 2017


On 07/10/17 06:09, Ben Chan wrote:
> The 'port' field in DetailedRegistrationStateContext is initialized to
> NULL but never updated or used.
> 
> When detailed_registration_state_context_complete_and_free() calls
> g_object_unref() on the NULL 'port' field, an assertion is raised.

Pushed to git master, thanks!

> ---
>  plugins/anydata/mm-broadband-modem-anydata.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/plugins/anydata/mm-broadband-modem-anydata.c b/plugins/anydata/mm-broadband-modem-anydata.c
> index 4a1da0f9..4b579da1 100644
> --- a/plugins/anydata/mm-broadband-modem-anydata.c
> +++ b/plugins/anydata/mm-broadband-modem-anydata.c
> @@ -50,7 +50,6 @@ typedef struct {
>  typedef struct {
>      MMBroadbandModem *self;
>      GSimpleAsyncResult *result;
> -    MMPortSerialAt *port;
>      MMModemCdmaRegistrationState cdma1x_state;
>      MMModemCdmaRegistrationState evdo_state;
>      GError *error;
> @@ -71,7 +70,6 @@ detailed_registration_state_context_complete_and_free (DetailedRegistrationState
>      }
>  
>      g_simple_async_result_complete (ctx->result);
> -    g_object_unref (ctx->port);
>      g_object_unref (ctx->result);
>      g_object_unref (ctx->self);
>      g_free (ctx);
> 


-- 
Aleksander
https://aleksander.es


More information about the ModemManager-devel mailing list