summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Shane Garrett2018-03-27 14:47:30 -0400
committerGravatar Nikias Bassen2020-02-20 02:50:27 +0100
commit3d8d13f0a70cefc1b12571b7f6aa2d1d4c58cffb (patch)
treee6e002d163d0220abe3a12468b962853660e0899 /src
parent505e84f7f6ad41e751488309e67d2e8e45c2ec97 (diff)
downloadlibimobiledevice-3d8d13f0a70cefc1b12571b7f6aa2d1d4c58cffb.tar.gz
libimobiledevice-3d8d13f0a70cefc1b12571b7f6aa2d1d4c58cffb.tar.bz2
debugserver: Fix argv encoding
The encoding of the "A" command in idevicedebug had issues when encoding a character with a value > 0x7F such as some UTF-8 characters.
Diffstat (limited to 'src')
-rw-r--r--src/debugserver.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/debugserver.c b/src/debugserver.c
index ceaf4a9..c517017 100644
--- a/src/debugserver.c
+++ b/src/debugserver.c
@@ -599,8 +599,8 @@ LIBIMOBILEDEVICE_API debugserver_error_t debugserver_client_set_argv(debugserver
char *p = m;
char *q = (char*)argv[i];
while (*q) {
- *p++ = debugserver_int2hex(*q >> 4);
- *p++ = debugserver_int2hex(*q & 0xf);
+ *p++ = DEBUGSERVER_HEX_ENCODE_FIRST_BYTE(*q);
+ *p++ = DEBUGSERVER_HEX_ENCODE_SECOND_BYTE(*q);
q++;
}