Hi Hemant, On Wed, Apr 25, 2012 at 12:34 AM, Hemant Gupta <hemant.gupta@xxxxxxxxxxxxxx> wrote: > - /* FIXME: Get the correct LE addr type (public/random) */ > - device = device_create(connection, adapter, key, ADDR_TYPE_LE_PUBLIC); > + /* Check if address type and space can be parsed properly */ > + if (sscanf(value, "%d ", &addr_type) == 2) Are you sure "2" is the correct return value here? The manpage says: "These functions return the number of input items successfully matched and assigned [...]" So I would imagine it should return 1 if addr_type is filled, 0 otherwise. Can you verify this? (unless sscanf() counts the whitespace as input.) > + /* Increment by 2 (address type and space) */ > + value += 2; > + > + device = device_create(connection, adapter, key, addr_type); > if (!device) > return; Regards, -- Anderson Lizardo Instituto Nokia de Tecnologia - INdT Manaus - Brazil -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html