Просмотр исходного кода

base-files: ipcalc.sh: make check slightly more future-proof

The previous code handling the equal-condition might be removed or
altered in the future and the case might be overlooked.

Signed-off-by: Leon M. Busch-George <[email protected]>
Leon M. Busch-George 2 лет назад
Родитель
Сommit
25aab738ef
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      package/base-files/files/bin/ipcalc.sh

+ 1 - 1
package/base-files/files/bin/ipcalc.sh

@@ -89,7 +89,7 @@ BEGIN {
 		exit(1)
 		exit(1)
 	}
 	}
 
 
-	if (ipaddr > start && ipaddr < end) {
+	if (ipaddr >= start && ipaddr <= end) {
 		print "warning: ipaddr inside range - this might not be supported in future releases of Openwrt" > "/dev/stderr"
 		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
 		# turn this into an error after Openwrt 24 has been released
 		# exit(1)
 		# exit(1)