fix #4219 (log spam in debug builds)