From patchwork Fri Aug 8 10:51:23 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eduardo Abinader X-Patchwork-Id: 378172 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from maxx.maxx.shmoo.com (maxx.shmoo.com [205.134.188.171]) by ozlabs.org (Postfix) with ESMTP id 1CEAD140120 for ; Fri, 8 Aug 2014 20:50:01 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id A6B7217C0CA; Fri, 8 Aug 2014 06:49:59 -0400 (EDT) X-Virus-Scanned: amavisd-new at maxx.shmoo.com Received: from maxx.maxx.shmoo.com ([127.0.0.1]) by localhost (maxx.shmoo.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LERuv4CRwChD; Fri, 8 Aug 2014 06:49:59 -0400 (EDT) Received: from maxx.shmoo.com (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id 76B289D2E1; Fri, 8 Aug 2014 06:49:50 -0400 (EDT) X-Original-To: mailman-post+hostap@maxx.shmoo.com Delivered-To: mailman-post+hostap@maxx.shmoo.com Received: from localhost (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id CD05C17C0CB for ; Fri, 8 Aug 2014 06:49:48 -0400 (EDT) X-Virus-Scanned: amavisd-new at maxx.shmoo.com Received: from maxx.maxx.shmoo.com ([127.0.0.1]) by localhost (maxx.shmoo.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OdS6NH1kCflx for ; Fri, 8 Aug 2014 06:49:41 -0400 (EDT) Received: from mail-vc0-f170.google.com (mail-vc0-f170.google.com [209.85.220.170]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (not verified)) by maxx.maxx.shmoo.com (Postfix) with ESMTPS id D7E019D2E1 for ; Fri, 8 Aug 2014 06:49:41 -0400 (EDT) Received: by mail-vc0-f170.google.com with SMTP id lf12so8084115vcb.29 for ; Fri, 08 Aug 2014 03:49:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id; bh=W3O6quVUFEfu00nVK73PjdCNnvQp9pr0P/cetPf4ZgU=; b=LXlrljt9tb9J/uo0E3dAoYwzHTbmJVX+qctPTab8ScOm53aIqBgPu9Z2clpJbUULlw MXB97sIeM24ExdEw3nPBHxTlL9hb1oXrsxGIMxOigTLOoaAprECZ10NnvVRXg+g4PoV5 AHq+xQ/j2k8Erh7pl6R3DbXzuZ0rLfQIDFOyYkaqxG1NgmNC241hiLYPQIyEXCfCdbjJ GyM3OWvfF2k+7uIeZUFtYHG2LfvSokeuRgAUZgny3vxK6oweyzu2yhq6uC8XEWpqbRkx 5mpx9SyPtjoPCT1czQ8fv5NRt2fdhc6EgrpSDWh3MULrO2BkS/8snStkxRReZxcrEVPH OPgQ== X-Gm-Message-State: ALoCoQn3VtXt1UM2cyg5sUzWwtnJuKOoQsGHnNe8o/pyoQGBiysSZ3+J6y5uDoWe0ktFC7+mQgWT X-Received: by 10.52.0.132 with SMTP id 4mr4633889vde.10.1407494981442; Fri, 08 Aug 2014 03:49:41 -0700 (PDT) Received: from localhost.localdomain ([177.143.181.9]) by mx.google.com with ESMTPSA id bm9sm993853vec.6.2014.08.08.03.49.39 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 08 Aug 2014 03:49:40 -0700 (PDT) From: Eduardo Abinader To: hostap@lists.shmoo.com Subject: [PATCH] P2P: Use ssid instead of wpa_ssid to find GO iface Date: Fri, 8 Aug 2014 06:51:23 -0400 Message-Id: <1407495083-3213-1-git-send-email-eduardo.abinader@openbossa.org> X-Mailer: git-send-email 1.9.1 X-BeenThere: hostap@lists.shmoo.com X-Mailman-Version: 2.1.11 Precedence: list List-Id: HostAP Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: hostap-bounces@lists.shmoo.com Errors-To: hostap-bounces@lists.shmoo.com In order to find a GO interface, there has to be a comparison among two SSIDs, instead of a wpa_ssid and a ssid. Signed-off-by: Eduardo Abinader --- wpa_supplicant/p2p_supplicant.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c index f1269ad..5e2d49b 100644 --- a/wpa_supplicant/p2p_supplicant.c +++ b/wpa_supplicant/p2p_supplicant.c @@ -3706,7 +3706,7 @@ struct wpa_supplicant * wpas_get_p2p_go_iface(struct wpa_supplicant *wpa_s, s->mode != WPAS_MODE_P2P_GROUP_FORMATION) continue; if (s->ssid_len != ssid_len || - os_memcmp(s, s->ssid, ssid_len) != 0) + os_memcmp(ssid, s->ssid, ssid_len) != 0) continue; return wpa_s; }