Fixed windows compile errors