On Mon, 2015-10-05 at 15:35 +0530, Maneesh Jain wrote:
> Signed-off-by: Maneesh Jain <maneesh.j...@samsung.com>

We don't do/need signed-off-bys in this project. Short description here
of the cause of the fix like "If supplicant_dbus_property_get_all()
returns and error, the callback function will not be called and
property_data will not be freed" or such, so that the next person's
attention is focused on the fix and need not necessarily look up the
function to understand if this really was necessary.

> ---
>  gsupplicant/supplicant.c | 14 ++++++++++----
>  1 file changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c
> index 6a62026..ad53a56 100755
> --- a/gsupplicant/supplicant.c
> +++ b/gsupplicant/supplicant.c
> @@ -2779,7 +2779,8 @@ static void signal_peer_found(const char *path, 
> DBusMessageIter *iter)
>       GSupplicantInterface *interface;
>       const char *obj_path = NULL;
>       GSupplicantPeer *peer;
> -
> +     int ret;
> +     

NACK. Trailing whitespace. Please don't send MSDOS formatted patches,
all lines in the patch end with ^M.

>       SUPPLICANT_DBG("");
>  
>       interface = g_hash_table_lookup(interface_table, path);
> @@ -2816,10 +2817,15 @@ static void signal_peer_found(const char *path, 
> DBusMessageIter *iter)
>               peer_property(NULL, NULL, property_data);
>               return;
>       }
> +     
> +     ret = supplicant_dbus_property_get_all(obj_path,
> +                                             SUPPLICANT_INTERFACE ".Peer",
> +                                             peer_property, property_data, 
> NULL);
> +     if (ret < 0) {
> +             dbus_free(property_data);
> +             return;
> +     }
>  
> -     supplicant_dbus_property_get_all(obj_path,
> -                                     SUPPLICANT_INTERFACE ".Peer",
> -                                     peer_property, property_data, NULL);
>  }
>  
>  static void signal_peer_lost(const char *path, DBusMessageIter *iter)


        Patrik

_______________________________________________
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman

Reply via email to