Hi,

This patch set attempts to clean up nameserver handling in service.c.

update_nameservers() is split up into add and remove functionality in
order to ease understanding what is being done at which function call.
These changes ensure that nameservers can only be added and removed
when the corresponding IP configuration is connected. Therefore
removing and adding needs to happen before and after updating the
respective IP configuration state.

Search domains depend on the combined service state, thus they are
added and removed when the service is to change state.

An fix for reallocating already allocated strings is done in patch
2/4 and Saurav's patch properly removing nameservers with a was made
to work with these changes as patch 3/4.


Cheers,

        Patrik


Patrik Flykt (3):
  service: Clean up nameserver and search domain handling
  service: Use less memory allocation
  service: Remove duplicate function

Saurav Babu (1):
  service: Properly remove Nameservers with only one entry

 src/connman.h |   2 -
 src/dhcpv6.c  |   2 +-
 src/service.c | 268 ++++++++++++++++++++++++++++------------------------------
 3 files changed, 132 insertions(+), 140 deletions(-)

-- 
2.1.4

_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman

Reply via email to