Logging: avoid "cb was NULL" warning message during logging shutdown