win32: bzr can't set file attribute to hidden if file path contains unicode.

Bug #395010 reported by methane
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
Undecided
Unassigned

Bug Description

bzr uses "win32file.SetFileAttributes" to set file attribute.
But bzr should use "win32file.SetFileAttributesW" for path contains charactor not in current codepage.

In bzrlib/win32util.py:

 def set_file_attr_hidden(path):
     """Set file attributes to hidden if possible"""
     if has_win32file:
- win32file.SetFileAttributes(path, win32file.FILE_ATTRIBUTE_HIDDEN)
+ win32file.SetFileAttributesW(path, win32file.FILE_ATTRIBUTE_HIDDEN)

(Relating to: http://bugs.launchpad.net/tortoisebzr/+bug/335362/comments/41)

methane (songofacandy)
Changed in bzr:
status: New → Fix Committed
Vincent Ladeuil (vila)
Changed in bzr:
milestone: none → 1.17
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.