switched str[n]cmp to use == operator; removed __APPLE__ and __DARWIN__ specific code