fix some small issues in debug