Fix return type for Windows