Browse Source

Fix test on Python3 w/ Windows.

Jelmer Vernooij 8 years ago
parent
commit
6f1a08a75f
1 changed files with 1 additions and 0 deletions
  1. 1 0
      dulwich/index.py

+ 1 - 0
dulwich/index.py

@@ -440,6 +440,7 @@ def build_file_from_blob(blob, mode, target_path, honor_filemode=True):
             # TODO(jelmer): Don't assume tree_encoding == fs_encoding
             tree_encoding = sys.getfilesystemencoding()
             contents = contents.decode(tree_encoding)
+            target_path = target_path.decode(tree_encoding)
         os.symlink(contents, target_path)
     else:
         if oldstat is not None and oldstat.st_size == len(contents):