[gnome-network-displays] wfd-p2p-sink: Use device name instead of MAC for matching
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-network-displays] wfd-p2p-sink: Use device name instead of MAC for matching
- Date: Fri, 8 Jul 2022 10:18:03 +0000 (UTC)
commit ec1c3d134fe734c5ca555a60517752f699c7ee5c
Author: Christian Glombek <lorbus fedoraproject org>
Date: Fri Jun 24 22:25:08 2022 +0200
wfd-p2p-sink: Use device name instead of MAC for matching
src/nd-wfd-p2p-sink.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/nd-wfd-p2p-sink.c b/src/nd-wfd-p2p-sink.c
index 7690443..9369d4a 100644
--- a/src/nd-wfd-p2p-sink.c
+++ b/src/nd-wfd-p2p-sink.c
@@ -131,15 +131,15 @@ nd_wfd_p2p_sink_get_property (GObject *object,
case PROP_MATCHES:
{
g_autoptr(GPtrArray) res = NULL;
- const char *hw_addr;
+ const char *name;
res = g_ptr_array_new_with_free_func (g_free);
/* Should not usually happen, but it can if something is holding on
* to the sink. So guard against NULL being returned if the peer
* object is not valid anymore. */
- hw_addr = nm_wifi_p2p_peer_get_hw_address (sink->nm_peer);
- if (hw_addr)
- g_ptr_array_add (res, g_strdup (hw_addr));
+ name = nm_wifi_p2p_peer_get_name (sink->nm_peer);
+ if (name)
+ g_ptr_array_add (res, g_strdup (name));
g_value_take_boxed (value, g_steal_pointer (&res));
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]