just fix some corner case, before the osx build