Some fixes for debug console.