Fixed compilation warnings on mac os x.