summaryrefslogtreecommitdiffstats
path: root/libusbmuxd
diff options
context:
space:
mode:
Diffstat (limited to 'libusbmuxd')
-rw-r--r--libusbmuxd/libusbmuxd.c26
-rw-r--r--libusbmuxd/usbmuxd.h8
2 files changed, 17 insertions, 17 deletions
diff --git a/libusbmuxd/libusbmuxd.c b/libusbmuxd/libusbmuxd.c
index 6d4504b..0623b90 100644
--- a/libusbmuxd/libusbmuxd.c
+++ b/libusbmuxd/libusbmuxd.c
@@ -548,11 +548,11 @@ int get_next_event(int sfd, usbmuxd_event_cb_t callback, void *user_data)
devinfo->handle = dev->device_id;
devinfo->product_id = dev->product_id;
- memset(devinfo->uuid, '\0', sizeof(devinfo->uuid));
- memcpy(devinfo->uuid, dev->serial_number, sizeof(devinfo->uuid));
+ memset(devinfo->udid, '\0', sizeof(devinfo->udid));
+ memcpy(devinfo->udid, dev->serial_number, sizeof(devinfo->udid));
- if (strcasecmp(devinfo->uuid, "ffffffffffffffffffffffffffffffffffffffff") == 0) {
- sprintf(devinfo->uuid + 32, "%08x", devinfo->handle);
+ if (strcasecmp(devinfo->udid, "ffffffffffffffffffffffffffffffffffffffff") == 0) {
+ sprintf(devinfo->udid + 32, "%08x", devinfo->handle);
}
collection_add(&devices, devinfo);
@@ -733,11 +733,11 @@ retry:
devinfo->handle = dev->device_id;
devinfo->product_id = dev->product_id;
- memset(devinfo->uuid, '\0', sizeof(devinfo->uuid));
- memcpy(devinfo->uuid, dev->serial_number, sizeof(devinfo->uuid));
+ memset(devinfo->udid, '\0', sizeof(devinfo->udid));
+ memcpy(devinfo->udid, dev->serial_number, sizeof(devinfo->udid));
- if (strcasecmp(devinfo->uuid, "ffffffffffffffffffffffffffffffffffffffff") == 0) {
- sprintf(devinfo->uuid + 32, "%08x", devinfo->handle);
+ if (strcasecmp(devinfo->udid, "ffffffffffffffffffffffffffffffffffffffff") == 0) {
+ sprintf(devinfo->udid + 32, "%08x", devinfo->handle);
}
collection_add(&tmpdevs, devinfo);
@@ -799,7 +799,7 @@ int usbmuxd_device_list_free(usbmuxd_device_info_t **device_list)
return 0;
}
-int usbmuxd_get_device_by_uuid(const char *uuid, usbmuxd_device_info_t *device)
+int usbmuxd_get_device_by_udid(const char *udid, usbmuxd_device_info_t *device)
{
usbmuxd_device_info_t *dev_list = NULL;
@@ -813,17 +813,17 @@ int usbmuxd_get_device_by_uuid(const char *uuid, usbmuxd_device_info_t *device)
int i;
int result = 0;
for (i = 0; dev_list[i].handle > 0; i++) {
- if (!uuid) {
+ if (!udid) {
device->handle = dev_list[i].handle;
device->product_id = dev_list[i].product_id;
- strcpy(device->uuid, dev_list[i].uuid);
+ strcpy(device->udid, dev_list[i].udid);
result = 1;
break;
}
- if (!strcmp(uuid, dev_list[i].uuid)) {
+ if (!strcmp(udid, dev_list[i].udid)) {
device->handle = dev_list[i].handle;
device->product_id = dev_list[i].product_id;
- strcpy(device->uuid, dev_list[i].uuid);
+ strcpy(device->udid, dev_list[i].udid);
result = 1;
break;
}
diff --git a/libusbmuxd/usbmuxd.h b/libusbmuxd/usbmuxd.h
index eabd216..b8283d6 100644
--- a/libusbmuxd/usbmuxd.h
+++ b/libusbmuxd/usbmuxd.h
@@ -38,7 +38,7 @@ extern "C" {
typedef struct {
int handle;
int product_id;
- char uuid[41];
+ char udid[41];
} usbmuxd_device_info_t;
/**
@@ -104,9 +104,9 @@ int usbmuxd_get_device_list(usbmuxd_device_info_t **device_list);
int usbmuxd_device_list_free(usbmuxd_device_info_t **device_list);
/**
- * Gets device information for the device specified by uuid.
+ * Gets device information for the device specified by udid.
*
- * @param uuid A device uuid of the device to look for. If uuid is NULL,
+ * @param udid A device UDID of the device to look for. If udid is NULL,
* This function will return the first device found.
* @param device Pointer to a previously allocated (or static)
* usbmuxd_device_info_t that will be filled with the device info.
@@ -114,7 +114,7 @@ int usbmuxd_device_list_free(usbmuxd_device_info_t **device_list);
* @return 0 if no matching device is connected, 1 if the device was found,
* or a negative value on error.
*/
-int usbmuxd_get_device_by_uuid(const char *uuid, usbmuxd_device_info_t *device);
+int usbmuxd_get_device_by_udid(const char *udid, usbmuxd_device_info_t *device);
/**
* Request proxy connect to