Merge pull request #46 from stargieg/master
authorSteven Barth <steven@midlink.org>
Thu, 20 Aug 2015 05:47:02 +0000 (07:47 +0200)
committerSteven Barth <steven@midlink.org>
Thu, 20 Aug 2015 05:47:02 +0000 (07:47 +0200)
RFC: dhcpv4 support openwrt alias ip addr

1  2 
src/odhcpd.h

diff --combined src/odhcpd.h
@@@ -143,9 -143,10 +143,11 @@@ struct interface 
        int default_router;
        int managed;
        int route_preference;
 +      int ra_maxinterval;
  
        // DHCPv4
+       struct in_addr dhcpv4_addr;
+       struct in_addr dhcpv4_mask;
        struct in_addr dhcpv4_start;
        struct in_addr dhcpv4_end;
        struct in_addr *dhcpv4_router;
@@@ -193,8 -194,7 +195,8 @@@ struct interface* odhcpd_get_interface_
  struct interface* odhcpd_get_master_interface(void);
  int odhcpd_urandom(void *data, size_t len);
  void odhcpd_setup_route(const struct in6_addr *addr, int prefixlen,
 -              const struct interface *iface, const struct in6_addr *gw, bool add);
 +              const struct interface *iface, const struct in6_addr *gw,
 +              int metric, bool add);
  
  void odhcpd_run(void);
  time_t odhcpd_time(void);
@@@ -211,6 -211,8 +213,8 @@@ int init_ubus(void)
  const char* ubus_get_ifname(const char *name);
  void ubus_apply_network(void);
  bool ubus_has_prefix(const char *name, const char *ifname);
+ const char* ubus_get_address4(const char *name);
+ int ubus_get_mask4(const char *name);
  #endif