diff --git a/src/dnsmasq_interface.c b/src/dnsmasq_interface.c index 632518ce0..d22f0262f 100644 --- a/src/dnsmasq_interface.c +++ b/src/dnsmasq_interface.c @@ -4349,8 +4349,9 @@ void FTL_connection_error(const char *reason, const union mysockaddr *addr, cons // Log to FTL.log log_debug(DEBUG_QUERIES, "Connection error (%s#%u, ID %d): %s (%s)%s", ip, port, id, reason, error, extra); - // Log to pihole.log - my_syslog(priority, "%s: %s", reason, error); + // Log to pihole.log (unless the user asked us to hide these warnings) + if(!config.misc.hide_connection_error.v.b) + my_syslog(priority, "%s: %s", reason, error); // Add to Pi-hole diagnostics but do not add messages more often than // once every five seconds to avoid hammering the database with errors