Commit e4f3c9c
Fix string length computation for issue_command function
When arg is not a ascii char,
len(arg) may be differrent from len(arg.encode("utf-8")).
For example, a Chinese character `c`,
len(c) is 1, but len(c.encode("utf-8")) is 3,
which will raise an InvalidResponseError because of the wrong length.
This commit should fix this kind of problem.1 parent 955577d commit e4f3c9c
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
514 | 514 | | |
515 | 515 | | |
516 | 516 | | |
517 | | - | |
| 517 | + | |
518 | 518 | | |
519 | 519 | | |
520 | 520 | | |
| |||
0 commit comments