Send connman mailing list submissions to
        connman@lists.01.org

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.01.org/mailman/listinfo/connman
or, via email, send a message with subject or body 'help' to
        connman-requ...@lists.01.org

You can reach the person managing the list at
        connman-ow...@lists.01.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of connman digest..."


Today's Topics:

   1. [PATCH] ipconfig: Incase of Manual IP Configuration, saving
      Gateway information during network switch (Rahul Jain)
   2. [PATCH] [dnsproxy] Simplified udp_server_event() (Slava Monich)


----------------------------------------------------------------------

Message: 1
Date: Thu, 23 Aug 2018 17:25:47 +0530
From: Rahul Jain <rahul.j...@samsung.com>
To: "connman@lists.01.org" <connman@lists.01.org>
Cc: AMIT KUMAR JAISWAL <amit.jais...@samsung.com>
Subject: [PATCH] ipconfig: Incase of Manual IP Configuration, saving
        Gateway information during network switch
Message-ID:
        <20180823115547epcms5p620a18db16c08a3faa0f8ef60673db926@epcms5p6>
Content-Type: text/plain; charset="utf-8"

Subject: [PATCH] ipconfig: Incase of Manual IP Configuration, saving Gateway
 information during network switch

[Problem] If user use manual IP configuration while connect with 
network(suppose wired).
Then during network switch (suppose from wired to wireless), gateway will not 
be saved into
/var/lib/connman respective profile settings.
So when user come back to earlier network(suppose wired again),
then connection will fail as connman does not have gateway(wrong gateway as 
0.0.0.0) to connect.

[Solution] When device switch from wired to wireless network, gateway 
information was missed
to be saved into /var/lib/connman respective profile. So during Network switch
service_save()->__connman_ipconfig_save() will not remove "IPV4.gateway" key
from respective profile settings file.

Signed-off-by: Rahul Jain <rahul.j...@samsung.com>
---
 src/ipconfig.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/src/ipconfig.c b/src/ipconfig.c
index 2565773..a2e398d 100644
--- a/src/ipconfig.c
+++ b/src/ipconfig.c
@@ -2346,8 +2346,6 @@ int __connman_ipconfig_save(struct connman_ipconfig 
*ipconfig,
        if (ipconfig->address->gateway)
                g_key_file_set_string(keyfile, identifier,
                        key, ipconfig->address->gateway);
-       else
-               g_key_file_remove_key(keyfile, identifier, key, NULL);
        g_free(key);
 
        return 0;
-- 
2.7.4


------------------------------

Message: 2
Date: Thu, 23 Aug 2018 18:24:41 +0300
From: Slava Monich <slava.mon...@jolla.com>
To: connman@lists.01.org
Subject: [PATCH] [dnsproxy] Simplified udp_server_event()
Message-ID: <1535037881-6328-1-git-send-email-slava.mon...@jolla.com>

---
 src/dnsproxy.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/src/dnsproxy.c b/src/dnsproxy.c
index 1db3eae..49bc395 100644
--- a/src/dnsproxy.c
+++ b/src/dnsproxy.c
@@ -2231,7 +2231,7 @@ static gboolean udp_server_event(GIOChannel *channel, 
GIOCondition condition,
                                                        gpointer user_data)
 {
        unsigned char buf[4096];
-       int sk, err, len;
+       int sk, len;
        struct server_data *data = user_data;
 
        if (condition & (G_IO_NVAL | G_IO_ERR | G_IO_HUP)) {
@@ -2243,12 +2243,9 @@ static gboolean udp_server_event(GIOChannel *channel, 
GIOCondition condition,
        sk = g_io_channel_unix_get_fd(channel);
 
        len = recv(sk, buf, sizeof(buf), 0);
-       if (len < 12)
-               return TRUE;
 
-       err = forward_dns_reply(buf, len, IPPROTO_UDP, data);
-       if (err < 0)
-               return TRUE;
+       if (len >= 12)
+               forward_dns_reply(buf, len, IPPROTO_UDP, data);
 
        return TRUE;
 }
-- 
1.9.1



------------------------------

Subject: Digest Footer

_______________________________________________
connman mailing list
connman@lists.01.org
https://lists.01.org/mailman/listinfo/connman


------------------------------

End of connman Digest, Vol 34, Issue 13
***************************************

Reply via email to