aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMarek Kwaczynski <marek.kwaczynski@tieto.com>2011-12-18 14:38:48 (GMT)
committerJouni Malinen <j@w1.fi>2011-12-18 14:38:48 (GMT)
commit2f0c8936bfe1d08568ef860a81bfc4c5f3bcc51d (patch)
treeef27bf7be9cfe120af3bec77850c816f91f0d15d /src
parentf2fe5b366337a274a42ab049e0b5673f527d3c5d (diff)
downloadhostap-2f0c8936bfe1d08568ef860a81bfc4c5f3bcc51d.zip
hostap-2f0c8936bfe1d08568ef860a81bfc4c5f3bcc51d.tar.gz
hostap-2f0c8936bfe1d08568ef860a81bfc4c5f3bcc51d.tar.bz2
P2P: Do not include own information in the peer table
When the station is connected to P2P GO after calling p2p_find command the device sees itself. It is related to lack of filtering itself from clients connected to P2P GO. Step by step: 1. dev1: p2p_group_add 2. dev2: p2p_connect <MAC1> pbc join 3. dev1: wps_pbc 4. dev2: p2p_find Skip P2P client information for our own device from a GO with which we are connected.
Diffstat (limited to 'src')
-rw-r--r--src/p2p/p2p.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/p2p/p2p.c b/src/p2p/p2p.c
index 7697256..79059ad 100644
--- a/src/p2p/p2p.c
+++ b/src/p2p/p2p.c
@@ -404,6 +404,9 @@ static int p2p_add_group_clients(struct p2p_data *p2p, const u8 *go_dev_addr,
for (c = 0; c < info.num_clients; c++) {
struct p2p_client_info *cli = &info.client[c];
+ if (os_memcmp(cli->p2p_device_addr, p2p->cfg->dev_addr,
+ ETH_ALEN) == 0)
+ continue; /* ignore our own entry */
dev = p2p_get_device(p2p, cli->p2p_device_addr);
if (dev) {
/*