summaryrefslogtreecommitdiff
path: root/util/uuid.c
diff options
context:
space:
mode:
Diffstat (limited to 'util/uuid.c')
-rw-r--r--util/uuid.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/util/uuid.c b/util/uuid.c
index ebf06c049a..5787f0978c 100644
--- a/util/uuid.c
+++ b/util/uuid.c
@@ -110,10 +110,10 @@ int qemu_uuid_parse(const char *str, QemuUUID *uuid)
/* Swap from UUID format endian (BE) to the opposite or vice versa.
*/
-void qemu_uuid_bswap(QemuUUID *uuid)
+QemuUUID qemu_uuid_bswap(QemuUUID uuid)
{
- assert(QEMU_PTR_IS_ALIGNED(uuid, sizeof(uint32_t)));
- bswap32s(&uuid->fields.time_low);
- bswap16s(&uuid->fields.time_mid);
- bswap16s(&uuid->fields.time_high_and_version);
+ bswap32s(&uuid.fields.time_low);
+ bswap16s(&uuid.fields.time_mid);
+ bswap16s(&uuid.fields.time_high_and_version);
+ return uuid;
}