fixed kernel compilation warnings on MacOSX