fixed #1 crash on Windows