ddns-scripts: initialise the is_glue variable

Improve the code as suggested by Christian Schoenebeck.

Signed-off-by: Mathias Kresin <dev@kresin.me>
This commit is contained in:
Mathias Kresin
2016-06-04 07:30:53 +02:00
parent 9946769206
commit ed11871c56
4 changed files with 4 additions and 4 deletions
@@ -131,6 +131,7 @@ ERR_LAST=$? # save return code - equal 0 if SECTION_ID found
[ -z "$force_ipversion" ] && force_ipversion=0 # default let system decide
[ -z "$force_dnstcp" ] && force_dnstcp=0 # default UDP
[ -z "$ip_source" ] && ip_source="network"
[ -z "$is_glue" ] && is_glue=0 # default the ddns record is not a glue record
[ "$ip_source" = "network" -a -z "$ip_network" -a $use_ipv6 -eq 0 ] && ip_network="wan" # IPv4: default wan
[ "$ip_source" = "network" -a -z "$ip_network" -a $use_ipv6 -eq 1 ] && ip_network="wan6" # IPv6: default wan6
[ "$ip_source" = "web" -a -z "$ip_url" -a $use_ipv6 -eq 0 ] && ip_url="http://checkip.dyndns.com"