diff options
Diffstat (limited to 'global-functions')
-rw-r--r-- | global-functions | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/global-functions b/global-functions index df286b5..8d8ac1c 100644 --- a/global-functions +++ b/global-functions @@ -323,6 +323,7 @@ :global EmailQueue; :global EitherOr; + :global IsDNSResolving; :global IsTimeSync; :global LogPrintExit2; @@ -334,6 +335,11 @@ :return false; } + :if ([ :typeof [ :toip [ /tool/e-mail/get address ] ] ] != "ip" && [ $IsDNSResolving ] = false) do={ + $LogPrintExit2 debug $0 ("Server address is a DNS name and resolving fails, not flushing.") false; + :return false; + } + :if ([ :len [ /system/scheduler/find where name="FlushEmailQueue" ] ] > 0 && $QueueLen = 0) do={ $LogPrintExit2 warning $0 ("Flushing E-Mail messages from scheduler, but queue is empty.") false; } |