fix some small bug to silence the compiler