minor OS detection optimization