Fix sync and whoami on windows.
Merge pull request #380 from xmasotto/master

Fix sync and whoami on windows.