2012-05-11 15:45:35

by Paulo Alcantara

[permalink] [raw]
Subject: [PATCH BlueZ v2] core: Remove unused variable

"srcaddr" variable is not used for anything else in
btd_event_remote_name() function. So, remove it for now.
---
src/event.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/src/event.c b/src/event.c
index 514744b..8ecb942 100644
--- a/src/event.c
+++ b/src/event.c
@@ -318,7 +318,6 @@ void btd_event_remote_class(bdaddr_t *local, bdaddr_t *peer, uint32_t class)
void btd_event_remote_name(bdaddr_t *local, bdaddr_t *peer, char *name)
{
struct btd_adapter *adapter;
- char srcaddr[18];
struct btd_device *device;
struct remote_dev_info *dev_info;

@@ -339,8 +338,6 @@ void btd_event_remote_name(bdaddr_t *local, bdaddr_t *peer, char *name)
if (!get_adapter_and_device(local, peer, &adapter, &device, FALSE))
return;

- ba2str(local, srcaddr);
-
dev_info = adapter_search_found_devices(adapter, peer);
if (dev_info) {
g_free(dev_info->name);
--
1.7.5.4



2012-05-16 07:50:38

by Johan Hedberg

[permalink] [raw]
Subject: Re: [PATCH BlueZ v2] core: Remove unused variable

Hi Paulo,

On Fri, May 11, 2012, Paulo Alcantara wrote:
> "srcaddr" variable is not used for anything else in
> btd_event_remote_name() function. So, remove it for now.
> ---
> src/event.c | 3 ---
> 1 files changed, 0 insertions(+), 3 deletions(-)

Applied. Thanks.

Johan