Continue to refactor OS specific code