Skip to content

Commit b8bcada

Browse files
mywtony
authored andcommitted
Force tmux_command to parse UTF-8 unicode in Python 2
1 parent 6e9efa7 commit b8bcada

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libtmux/common.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
from distutils.version import LooseVersion
1515

1616
from . import exc
17-
from ._compat import console_to_str
17+
from ._compat import console_to_str, text_type
1818

1919
logger = logging.getLogger(__name__)
2020

@@ -196,7 +196,7 @@ def __init__(self, *args, **kwargs):
196196

197197
cmd = [tmux_bin]
198198
cmd += args # add the command arguments to cmd
199-
cmd = [str(c) for c in cmd]
199+
cmd = [text_type(c, encoding='utf_8') for c in cmd]
200200

201201
self.cmd = cmd
202202

0 commit comments

Comments
 (0)