Browse Source

ddns-scripts: fix/update to version 2.4.3-1

fixed sed when filtering IP address from nslookup output
because "Server:" block might have multiple address lines.
Thanks to Arjen de Korte

Signed-off-by: Christian Schoenebeck <christian.schoenebeck@gmail.com>
lilik-openwrt-22.03
Christian Schoenebeck 10 years ago
parent
commit
3788dd697b
2 changed files with 4 additions and 4 deletions
  1. +1
    -1
      net/ddns-scripts/Makefile
  2. +3
    -3
      net/ddns-scripts/files/dynamic_dns_functions.sh

+ 1
- 1
net/ddns-scripts/Makefile View File

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=ddns-scripts
# Version == major.minor.patch
# increase on new functionality (minor) or patches (patch)
PKG_VERSION:=2.4.2
PKG_VERSION:=2.4.3
# Release == build
# increase on changes of services files or tld_names.dat
PKG_RELEASE:=1


+ 3
- 3
net/ddns-scripts/files/dynamic_dns_functions.sh View File

@ -486,8 +486,8 @@ verify_host_port() {
__IPV4=$(cat $DATFILE | awk -F "address " '/has address/ {print $2; exit}' )
__IPV6=$(cat $DATFILE | awk -F "address " '/has IPv6/ {print $2; exit}' )
else # use BusyBox nslookup
__IPV4=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($IPV4_REGEX\).*$/\\1/p }")
__IPV6=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($IPV6_REGEX\).*$/\\1/p }")
__IPV4=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($IPV4_REGEX\).*$/\\1/p }")
__IPV6=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($IPV6_REGEX\).*$/\\1/p }")
fi
}
@ -966,7 +966,7 @@ get_registered_ip() {
if [ "$__PROG" = "BIND host" ]; then
__DATA=$(cat $DATFILE | awk -F "address " '/has/ {print $2; exit}' )
else
__DATA=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($__REGEX\).*$/\\1/p }" )
__DATA=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($__REGEX\).*$/\\1/p }" )
fi
[ -n "$__DATA" ] && {
write_log 7 "Registered IP '$__DATA' detected"


Loading…
Cancel
Save