diff options
author | Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com> | 2017-01-20 11:07:21 +0100 |
---|---|---|
committer | Jukka Rissanen <jukka.rissanen@linux.intel.com> | 2017-01-27 12:35:52 +0200 |
commit | aa84d81f2513f97cc9c2b10f7d789e2b753fc12a (patch) | |
tree | b6f3ca9040ffa8d61406e8bfc09d4200927755d5 | |
parent | a7e82666bc70923e33a5e3241437c9d4eae9333f (diff) |
net: ip: Add a useful macro to staticaly initialize a struct in_addr
As for IN6ADDR_ANY_INIT, let's have an INADDR_ANY_INIT.
Change-Id: I07c9ec6d2bb20d3a228edaac2e3380942feac5fd
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
-rw-r--r-- | include/net/net_ip.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/net/net_ip.h b/include/net/net_ip.h index c285cf2c9..7845c0944 100644 --- a/include/net/net_ip.h +++ b/include/net/net_ip.h @@ -160,6 +160,7 @@ struct net_addr { #define NET_IPV4_ADDR_LEN sizeof("xxx.xxx.xxx.xxx") #define INADDR_ANY 0 +#define INADDR_ANY_INIT { { { INADDR_ANY } } } #define NET_IPV6_MTU 1280 |