Merge pull request #154 from thedax/master

Use wide paths on Win32.
Only append a slash to the directory if there isn't one on the end.