summaryrefslogtreecommitdiffstats
path: root/libusbmuxd/libusbmuxd.c
diff options
context:
space:
mode:
authorGravatar Hector Martin2010-06-12 11:25:09 +0200
committerGravatar Hector Martin2010-06-12 11:25:09 +0200
commite1da26918aa8eb025cf18216efce61b2b4cf64b8 (patch)
tree91e67cea1f19e765518dcebfcc726315fb127697 /libusbmuxd/libusbmuxd.c
parent4a188de4bb6fdcd1f2f6fe523360e6c31e84e064 (diff)
downloadusbmuxd-e1da26918aa8eb025cf18216efce61b2b4cf64b8.tar.gz
usbmuxd-e1da26918aa8eb025cf18216efce61b2b4cf64b8.tar.bz2
Send the port number in screwed up endian in the plist (Apple compat)
Diffstat (limited to 'libusbmuxd/libusbmuxd.c')
-rw-r--r--libusbmuxd/libusbmuxd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libusbmuxd/libusbmuxd.c b/libusbmuxd/libusbmuxd.c
index 80ffdd7..564adcb 100644
--- a/libusbmuxd/libusbmuxd.c
+++ b/libusbmuxd/libusbmuxd.c
@@ -329,7 +329,7 @@ static int send_connect_packet(int sfd, uint32_t tag, uint32_t device_id, uint16
plist_dict_insert_item(plist, "ClientVersionString", plist_new_string(PLIST_CLIENT_VERSION_STRING));
plist_dict_insert_item(plist, "MessageType", plist_new_string("Connect"));
plist_dict_insert_item(plist, "DeviceID", plist_new_uint(device_id));
- plist_dict_insert_item(plist, "PortNumber", plist_new_uint(port));
+ plist_dict_insert_item(plist, "PortNumber", plist_new_uint(htons(port)));
plist_dict_insert_item(plist, "ProgName", plist_new_string(PLIST_PROGNAME));
plist_to_xml(plist, &payload, &payload_size);
plist_free(plist);