From 5db77f7c31d6c992a61c4a6ecfe3266f9e063d67 Mon Sep 17 00:00:00 2001 From: Richard Hansen Date: Fri, 12 Jul 2024 18:28:27 -0400 Subject: [PATCH] zoneedit1: Add TODO comments for problematic bits of code --- ddclient.in | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ddclient.in b/ddclient.in index bef4c32..c3b97b6 100755 --- a/ddclient.in +++ b/ddclient.in @@ -4662,6 +4662,8 @@ sub nic_zoneedit1_update { next if !header_ok($hosts, $reply); my @reply = split /\n/, $reply; + # TODO: This is awkward and fragile -- it assumes that each line in the response body + # corresponds with each host in @hosts (and in the same order). for my $line (@reply) { if ($h && $line =~ /^[^<]*<(SUCCESS|ERROR)\s+([^>]+)>(.*)/) { my ($status, $assignments, $rest) = ($1, $2, $3); @@ -4692,6 +4694,7 @@ sub nic_zoneedit1_update { redo if $line; } } + # TODO: Shouldn't this log join(',' @hosts) instead of $hosts? failed("updating %s: no response from %s", $hosts, $config{$h}{'server'}) if @hosts; }