Windows: handle newlines correctly
Merge pull request #125 from gordon/windows

Windows: handle newlines correctly