From fe09757cb31cf32818c9c001a389798231b8bd77 Mon Sep 17 00:00:00 2001 From: Jim Ma Date: Fri, 5 Aug 2016 21:31:12 +0800 Subject: [PATCH] dns_cx.sh prefix and suffix domain bug fixed --- dnsapi/dns_cx.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dnsapi/dns_cx.sh b/dnsapi/dns_cx.sh index 33e05e4b..b0cf36d0 100755 --- a/dnsapi/dns_cx.sh +++ b/dnsapi/dns_cx.sh @@ -145,7 +145,7 @@ _get_root() { fi if printf "$response" | grep "$h." >/dev/null ; then - seg=$(printf "$response" | grep -o "{[^{]*$h\.[^}]*\}" ) + seg=$(printf "$response" | grep -o "{[^{]*\"$h\.\"[^}]*\}" ) _debug seg "$seg" _domain_id=$(printf "$seg" | grep -o \"id\":\"[^\"]*\" | cut -d : -f 2 | tr -d \") _debug _domain_id "$_domain_id"