Send connman mailing list submissions to
        [email protected]

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
        [email protected]

You can reach the person managing the list at
        [email protected]

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


Today's Topics:

   1. [PATCHv2] inet: Corrected usage of unsigned int data-type.
      (Niraj Kumar Goit)
   2. [PATCH] wifi:Get interface name provided by netlink in
      src/device.c (Niraj Kumar Goit)
   3. [PATCH] client: Corrected format specifier for
      DBUS_TYPE_UINT64. (Niraj Kumar Goit)
   4. Re: [RFC v0 0/3] Refactoring firewall and iptables code
      (Patrik Flykt)


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

Message: 1
Date: Fri, 04 Mar 2016 08:48:52 +0530
From: Niraj Kumar Goit <[email protected]>
To: [email protected]
Cc: [email protected]
Subject: [PATCHv2] inet: Corrected usage of unsigned int data-type.
Message-ID: <[email protected]>

unsigned integer never falls below 0, so it is not useful to
compare unsigned int data-type for negative values.
---
v2: changed 'd = 0' to 'd == 0'

 src/inet.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/inet.c b/src/inet.c
index dc788ea..cdc2479 100644
--- a/src/inet.c
+++ b/src/inet.c
@@ -2565,7 +2565,7 @@ bool connman_inet_check_hostname(const char *ptr, size_t 
len)
                         */
                        size_t d = p - ptr;
 
-                       if ((d <= 0) || (d >= 64))
+                       if ((d == 0) || (d >= 64))
                                return false;
 
                        ptr = p + 1; /* Jump to the next label */
-- 
1.7.9.5




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

Message: 2
Date: Fri, 04 Mar 2016 11:18:29 +0530
From: Niraj Kumar Goit <[email protected]>
To: [email protected]
Cc: [email protected]
Subject: [PATCH] wifi:Get interface name provided by netlink in
        src/device.c
Message-ID: <[email protected]>

connman/TODO: Instead of using ioctls in connman_inet_ifname,
utilize the information already provided by netlink in src/device.c.
---
 plugins/wifi.c |    8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/plugins/wifi.c b/plugins/wifi.c
index bb1cabc..1e5ec52 100644
--- a/plugins/wifi.c
+++ b/plugins/wifi.c
@@ -1479,25 +1479,21 @@ static void interface_create_callback(int result,
 static int wifi_enable(struct connman_device *device)
 {
        struct wifi_data *wifi = connman_device_get_data(device);
-       int index;
-       char *interface;
+       const char *interface = connman_device_get_string(device, "Interface");
        const char *driver = connman_option_get_string("wifi");
        int ret;
 
        DBG("device %p %p", device, wifi);
 
-       index = connman_device_get_index(device);
-       if (!wifi || index < 0)
+       if (!wifi)
                return -ENODEV;
 
        if (is_p2p_connecting())
                return -EINPROGRESS;
 
-       interface = connman_inet_ifname(index);
        ret = g_supplicant_interface_create(interface, driver, NULL,
                                                interface_create_callback,
                                                        wifi);
-       g_free(interface);
 
        if (ret < 0)
                return ret;
-- 
1.7.9.5




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

Message: 3
Date: Fri, 04 Mar 2016 12:02:16 +0530
From: Niraj Kumar Goit <[email protected]>
To: [email protected]
Cc: [email protected]
Subject: [PATCH] client: Corrected format specifier for
        DBUS_TYPE_UINT64.
Message-ID: <[email protected]>

---
 client/dbus_helpers.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/client/dbus_helpers.c b/client/dbus_helpers.c
index 461266c..1ba7e6f 100644
--- a/client/dbus_helpers.c
+++ b/client/dbus_helpers.c
@@ -116,7 +116,7 @@ void __connmanctl_dbus_print(DBusMessageIter *iter, const 
char *pre,
 
                case DBUS_TYPE_UINT64:
                        dbus_message_iter_get_basic(iter, &u64);
-                       fprintf(stdout, "%lu", u64);
+                       fprintf(stdout, "%llu", u64);
                        break;
 
                case DBUS_TYPE_DOUBLE:
-- 
1.7.9.5




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

Message: 4
Date: Fri, 04 Mar 2016 10:41:35 +0200
From: Patrik Flykt <[email protected]>
To: Daniel Wagner <[email protected]>
Cc: [email protected], Daniel Wagner <[email protected]>
Subject: Re: [RFC v0 0/3] Refactoring firewall and iptables code
Message-ID: <[email protected]>
Content-Type: text/plain; charset="UTF-8"

On Wed, 2016-03-02 at 09:49 +0100, Daniel Wagner wrote:
> From: Daniel Wagner <[email protected]>
> 
> Hi,
> 
> here is the initial refactoring part for getting nftables support.
> 
> As you notice the arguments for the nat API is not as we discussed.
> The main reason for this is that if we use struct connman_ipconfig as
> argument tools/iptables-unit.c will pull in the complete ConnMan src
> directory. I dropped the firewall tests just to get it compiling
> again. Maybe we just delete those tests and have only iptables 'unit'
> tests. In this case the nat API with struct connman_ipconfig could
> just work fine.
> 
> All is just compile tested only. I just wanted to hear if this
> direction is okay with you guys. And if yes, I'd like to get this in
> before doing the nftables implementation.
> 
> What do you think?

Yes, we need this kind of "feature" API to be able to support nftables
in the future. I'm not totally jumping up and down of joy with the name
"firewall" but that is not an issue one should worry about now. Keep the
name and continue hacking!

Cheers,

        Patrik



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

Subject: Digest Footer

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


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

End of connman Digest, Vol 5, Issue 5
*************************************

Reply via email to