Fix filename option (windows).

This commit is contained in:
Nuno Cruces 2021-05-07 14:02:44 +01:00
parent e03bf87915
commit d6dcc4b176

View file

@ -350,7 +350,7 @@ func initDirNameExt(filename string, name []uint16) (dir *uint16, ext *uint16) {
d, n := splitDirAndName(filename)
e := filepath.Ext(n)
if n != "" {
copy(name, syscall.StringToUTF16(filename))
copy(name, syscall.StringToUTF16(n))
}
if d != "" {
dir = syscall.StringToUTF16Ptr(d)