Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
CentralNic
rdnsd
Commits
f4fc9737
Unverified
Commit
f4fc9737
authored
Aug 16, 2019
by
Gavin Brown
Browse files
check if we have an empty set of IPs. suppress exceptions
parent
567dfe3f
Changes
1
Hide whitespace changes
Inline
Side-by-side
rdnsd
View file @
f4fc9737
...
...
@@ -181,11 +181,16 @@ sub main_loop {
#
my
@ips
=
resolve
(
$ns
,
$CONF
->
{'
AddressFamily
'});
foreach
my
$proto
(
@PROTOCOLS
)
{
#
# spawn thread
#
$threads
->
{
$ns
}
->
{
$proto
}
=
threads
->
create
(
\
&time_query
,
(
$CONF
->
{'
AddressFamily
'},
$proto
,
@ips
));
if
(
scalar
(
@ips
)
<
1
)
{
debug
('
unable to resolve %s
',
uc
(
$ns
));
}
else
{
foreach
my
$proto
(
@PROTOCOLS
)
{
#
# spawn thread
#
$threads
->
{
$ns
}
->
{
$proto
}
=
threads
->
create
(
\
&time_query
,
(
$CONF
->
{'
AddressFamily
'},
$proto
,
@ips
));
}
}
}
...
...
@@ -218,11 +223,6 @@ sub main_loop {
#
sleep
(
$CONF
->
{'
Loop
'}
-
$dt
)
if
(
$dt
<
$CONF
->
{'
Loop
'});
};
if
(
$@
)
{
chomp
(
$@
);
debug
(
$@
);
}
}
#
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment