Fixes for windows platform