fix OS X compilation issue