[gnome-code-assistance] clang: encode path before using it



commit ef0ae2bbc64b23774da497b5c85a613bd0924e11
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Tue Mar 11 09:25:32 2014 +0100

    clang: encode path before using it

 backends/c/clang/cindex.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/backends/c/clang/cindex.py b/backends/c/clang/cindex.py
index 1736c27..44ba925 100644
--- a/backends/c/clang/cindex.py
+++ b/backends/c/clang/cindex.py
@@ -2204,6 +2204,9 @@ class TranslationUnit(ClangObject):
         if unsaved_files is None:
             unsaved_files = []
 
+        if isinstance(path, str):
+            path = path.encode('utf-8')
+
         unsaved_files_array = 0
         if len(unsaved_files):
             unsaved_files_array = (_CXUnsavedFile * len(unsaved_files))()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]