added code for checking os type