openwrt / odhcpd

This repository is a mirror of https://git.openwrt.org/?p=project/odhcpd.git. Pull requests will be accepted which will be merged in odhcpd.git
GNU General Public License v2.0
161 stars 98 forks source link

dhcpv4_assign: rework the assignment logic #29

Closed mehlis closed 9 years ago

mehlis commented 9 years ago

RFC: I just want to hear your opinion on the new code.

the code tries to:

  1. assign the requested IP
  2. assign the mapped IP
  3. assign the mapped IP + 1 (and walk in the possible space with mod and stuff)

question: is the order in iface->dhcpv4_assignments relevant for other code parts?

mehlis commented 9 years ago

@sbyx this code is heavily tested and runs in production on consumer devices. Do you think you have a better solution or are there any comments on this changeset?

sbyx commented 9 years ago

Sorry must have been lost at some point. I'm currently working on a major overhaul of the address-assignment code unifying v6 and v4, but I'm not sure when I will finish. I can still merge this for now, thanks.