base-files: ipcalc.sh: turn error into warning
authorLeon M. Busch-George <leon@georgemail.eu>
Sun, 20 Aug 2023 19:08:20 +0000 (21:08 +0200)
committerLeon M. Busch-George <leon@georgemail.eu>
Mon, 25 Sep 2023 13:02:49 +0000 (15:02 +0200)
Some users have their routers configured to supply a DHCP range that
includes the local interface address.
That worked with dnsmasq because it automatically skips the local
address.

Re-enable those existing configurations for the release and hint at
possible future problems.

Signed-off-by: Leon M. Busch-George <leon@georgemail.eu>
[ wrap commit description and remove unecessary text ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
package/base-files/files/bin/ipcalc.sh

index 0132e8d9bf4da4025b3a0d5f516bbb25fb010d6a..25114219a1065e12a600649843d3fa5e04094d5e 100755 (executable)
@@ -90,8 +90,9 @@ BEGIN {
        }
 
        if (ipaddr > start && ipaddr < end) {
-               print "ipaddr inside range" > "/dev/stderr"
-               exit(1)
+               print "warning: ipaddr inside range - this might not be supported in future releases of Openwrt" > "/dev/stderr"
+               # turn this into an error after Openwrt 24 has been released
+               # exit(1)
        }
 
        print "START="int2ip(start)