resolve #5, -logging option got applied after some logging statements