[PATCH] gresolv: Destroy query at the relevant place when parsing the response

2013-01-28 Thread Tomasz Bursztyka
parse_response() will eventually call sort_and_return_results() which in turn, will call the result function. But the result function might cancel the gresolv. At the point: all queries belonging to this gresolv are destroyed. Back to parse_response(), it calls again destroy_query() on an already d

[PATCH] gresolv: Destroy query at the relevant place when parsing the response

2013-01-28 Thread Tomasz Bursztyka
parse_response() will eventually call sort_and_return_results() which in turn, will call the result function. But the result function might cancel the gresolv. At the point: all queries belonging to this gresolv are destroyed. Back to parse_response(), it calls again destroy_query() on an already d

Re: [PATCH] gresolv: Destroy query at the relevant place when parsing the response

2013-01-28 Thread Patrik Flykt
On Mon, 2013-01-28 at 15:43 +0200, Tomasz Bursztyka wrote: > parse_response() will eventually call sort_and_return_results() which in turn, > will call the result function. But the result function might cancel the > gresolv. > At the point: all queries belonging to this gresolv are destroyed. Back

[PATCH v4 03/18] technology: Remove unnecessary comparison and goto

2013-01-28 Thread patrik . flykt
From: Patrik Flykt --- src/technology.c |6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/technology.c b/src/technology.c index 8166d17..6f03c69 100644 --- a/src/technology.c +++ b/src/technology.c @@ -119,14 +119,11 @@ int connman_technology_driver_register(struct

[PATCH v4 13/18] network: Allow more than one network driver register the same type

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Allowing more than one network driver to register the same network type requires the network driver to properly identify which networks belong to it in the network driver probe function. --- src/network.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/src/net

[PATCH v4 12/18] bluetooth_legacy: Check network in probe function

2013-01-28 Thread patrik . flykt
From: Patrik Flykt The network probed can belong to the new Bluez 5 bluetooth plugin or to this plugin. Check if this plugin created the network and proceed accordingly. --- plugins/bluetooth_legacy.c | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/plugi

[PATCH v4 14/18] bluetooth: Expose Bluez 5 org.bluez.Network1 objects as networks

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Create ConnMan networks for those Bluez 5 org.bluez.Network1/Device1 objects that support PAN NAP. A network is created or removed in response to the Network1/Device1 being created or when the Device1 object's UUID changed. The ConnMan network struct is added to and removed fr

[PATCH v4 02/18] ofono: Use ordinary string instead of ident

2013-01-28 Thread patrik . flykt
From: Patrik Flykt The string is only used for debugging purposes. --- plugins/ofono.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/ofono.c b/plugins/ofono.c index 41954e4..b55a76d 100644 --- a/plugins/ofono.c +++ b/plugins/ofono.c @@ -963,7 +963,7 @@ static voi

[PATCH v4 16/18] bluetooth: Connect and disconnect a PAN NAP network

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Implement connect and disconnect functionality for a ConnMan network. On network creation check the connection status of the Bluez 5 Network1 object and set the network to connected when needed. --- plugins/bluetooth.c | 142 +--

[PATCH v4 18/18] bluetooth: Implement tethering for the Bluez 5 bluetooth plugin

2013-01-28 Thread patrik . flykt
From: Patrik Flykt --- plugins/bluetooth.c | 117 +++ 1 file changed, 117 insertions(+) diff --git a/plugins/bluetooth.c b/plugins/bluetooth.c index d9d09bd..4aac1e0 100644 --- a/plugins/bluetooth.c +++ b/plugins/bluetooth.c @@ -44,6 +44,7 @@ sta

[PATCH v4 01/18] dundee: Use ordinary string instead of ident

2013-01-28 Thread patrik . flykt
From: Patrik Flykt The string is only used for debugging purposes. --- plugins/dundee.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/dundee.c b/plugins/dundee.c index 0a48db1..7ebdfe9 100644 --- a/plugins/dundee.c +++ b/plugins/dundee.c @@ -96,7 +96,7 @@ static

[PATCH v4 00/18] Bluez 5 bluetooth plugin

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Hi, In hopefully what is the final Bluez 5 bluetooth plugin version, two patches are added. The first one (patch 17) now allows a technology to have more than one technology driver. This since tethering is controlled on the technology level while both the new and the

[PATCH v4 17/18] technology: Support multiple technology drivers

2013-01-28 Thread patrik . flykt
From: Patrik Flykt As tethering is enabled on the technology level, both the bluetooth and the bluetooth_legacy plugin need to register technology drivers for CONNMAN_SERVICE_TYPE_BLUETOOTH. Modify the technology code to create a list of registered technology drivers instead of a single technolog

[PATCH v4 07/18] bluetooth: Add new bluetooth plugin

2013-01-28 Thread patrik . flykt
From: Patrik Flykt --- Makefile.plugins|2 ++ plugins/bluetooth.c | 49 + 2 files changed, 51 insertions(+) create mode 100644 plugins/bluetooth.c diff --git a/Makefile.plugins b/Makefile.plugins index 9271cac..aabaf73 100644 --- a/Make

[PATCH v4 09/18] technology: Enable/disable individual devices also with rfkill

2013-01-28 Thread patrik . flykt
From: Patrik Flykt In order to keep ConnMan devices in sync with Bluz 5 adapters, the individual devices need to be enabled/disabled also when unblocking/blocking them with rfkill. Thus enable devices after unblocking and disable devices before blocking with rfkill. --- src/technology.c | 20 +

[PATCH v4 11/18] bluetooth: Keep track of Bluez 5 org.bluez.Network1 objects

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Set up functions monitoring Bluez 5 org.bluez.Network1 objects being added and removed. Add a GDBusProxy for the org.bluez.Device1 object that corresponds to the Network1 object. Set up functions monitoring Network1 'Connected' and Device1 'UUID' properties. --- plugins/blueto

[PATCH v4 04/18] technology: Remove technology driver by pointer

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Compare the technology driver pointer to the driver being unregistered as the function is supposed to remove only the given driver. Also check if the driver has a remove function before calling it. --- src/technology.c |6 -- 1 file changed, 4 insertions(+), 2 deletio

[PATCH v4 05/18] technology: Check technology driver probe function before calling

2013-01-28 Thread patrik . flykt
From: Patrik Flykt --- src/technology.c |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/technology.c b/src/technology.c index 7f2303c..bc02bec 100644 --- a/src/technology.c +++ b/src/technology.c @@ -1002,7 +1002,11 @@ static struct connman_technology *technology_

[PATCH v4 08/18] bluetooth: Register technology driver

2013-01-28 Thread patrik . flykt
From: Patrik Flykt --- plugins/bluetooth.c | 32 +++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/plugins/bluetooth.c b/plugins/bluetooth.c index 1b5aed0..7e7c35e 100644 --- a/plugins/bluetooth.c +++ b/plugins/bluetooth.c @@ -28,20 +28,50 @@ #defi

[PATCH v4 10/18] bluetooth: Expose Bluez 5 adapters as ConnMan devices

2013-01-28 Thread patrik . flykt
From: Patrik Flykt Set up functions monitoring Bluez 5 objects being added and removed using GDBusProxy. When an adapter appears, create a new device for it and set up a watch function for the adapter's 'Powered' property. Keep the adapter 'Powered' property in sync with the device state and if

[PATCH v4 15/18] service: Must not return NULL with a synchronous GDBus method call

2013-01-28 Thread patrik . flykt
From: Patrik Flykt If NULL is returned, GDBus will call the registered function repeatedly. --- src/service.c |2 -- 1 file changed, 2 deletions(-) diff --git a/src/service.c b/src/service.c index 1e7cec7..a1d4a2f 100644 --- a/src/service.c +++ b/src/service.c @@ -3765,8 +3765,6 @@ static D