Fix some warnings on OS X