peer_info->primary_device_type,
peer_info->secondary_device_type
);
- if (peer_info->mac_address)
- free(peer_info->mac_address);
- if (peer_info->interface_address)
- free(peer_info->interface_address);
- if (peer_info)
- free(peer_info);
+ g_free(peer_info->mac_address);
+ g_free(peer_info->interface_address);
+ g_free(peer_info);
}
}
}
peer_info->primary_device_type,
peer_info->secondary_device_type
);
- if (peer_info->mac_address)
- free(peer_info->mac_address);
- if (peer_info->interface_address)
- free(peer_info->interface_address);
- if (peer_info)
- free(peer_info);
+ g_free(peer_info->mac_address);
+ g_free(peer_info->interface_address);
+ g_free(peer_info);
}
printf("wifi_direct_get_peer() result=[%d]\n", result);