Fix several compile warnings.