Fixes for compiling without debug logging