]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
P2P: Add new=0/1 flag to P2P-DEVICE-FOUND events
authorJouni Malinen <j@w1.fi>
Sun, 12 Oct 2014 13:45:33 +0000 (16:45 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 12 Oct 2014 13:45:33 +0000 (16:45 +0300)
This information can be used to determine whether the event is generated
for a new peer that was added or due to an update in the information for
an existing peer.

Signed-off-by: Jouni Malinen <j@w1.fi>
wpa_supplicant/p2p_supplicant.c

index 2aaee1fa35d6cc6043908bd5f8ad14a8b07620f7..f1aab72e40f7c513e8bc0b5771603f16c377b5c2 100644 (file)
@@ -1735,7 +1735,7 @@ static void wpas_dev_found(void *ctx, const u8 *addr,
        wpa_msg_global(wpa_s, MSG_INFO, P2P_EVENT_DEVICE_FOUND MACSTR
                       " p2p_dev_addr=" MACSTR
                       " pri_dev_type=%s name='%s' config_methods=0x%x "
-                      "dev_capab=0x%x group_capab=0x%x%s%s%s",
+                      "dev_capab=0x%x group_capab=0x%x%s%s%s new=%d",
                       MAC2STR(addr), MAC2STR(info->p2p_device_addr),
                       wps_dev_type_bin2str(info->pri_dev_type, devtype,
                                            sizeof(devtype)),
@@ -1743,7 +1743,8 @@ static void wpas_dev_found(void *ctx, const u8 *addr,
                       info->dev_capab, info->group_capab,
                       wfd_dev_info_hex ? " wfd_dev_info=0x" : "",
                       wfd_dev_info_hex ? wfd_dev_info_hex : "",
-                      info->vendor_elems ? " vendor_elems=1" : "");
+                      info->vendor_elems ? " vendor_elems=1" : "",
+                      new_device);
 
        os_free(wfd_dev_info_hex);
 #endif /* CONFIG_NO_STDOUT_DEBUG */