fix unterminated #ifdef from cherry-pick