Windows related fixes