Redirect log messages to the console.