fix inconsistent filenam issue for win32 (file vs string)