mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-04 02:45:22 +00:00
qemu: use GUINT32_SWAP_LE_BE
Use this GLib macro instead of bswap_32 from gnulib. Signed-off-by: Ján Tomko <jtomko@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
ec07893a5f
commit
a8ee07e0d1
@ -33,7 +33,6 @@
|
|||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <sys/un.h>
|
#include <sys/un.h>
|
||||||
#include <byteswap.h>
|
|
||||||
|
|
||||||
|
|
||||||
#include "qemu_driver.h"
|
#include "qemu_driver.h"
|
||||||
@ -2803,11 +2802,11 @@ struct _virQEMUSaveData {
|
|||||||
static inline void
|
static inline void
|
||||||
bswap_header(virQEMUSaveHeaderPtr hdr)
|
bswap_header(virQEMUSaveHeaderPtr hdr)
|
||||||
{
|
{
|
||||||
hdr->version = bswap_32(hdr->version);
|
hdr->version = GUINT32_SWAP_LE_BE(hdr->version);
|
||||||
hdr->data_len = bswap_32(hdr->data_len);
|
hdr->data_len = GUINT32_SWAP_LE_BE(hdr->data_len);
|
||||||
hdr->was_running = bswap_32(hdr->was_running);
|
hdr->was_running = GUINT32_SWAP_LE_BE(hdr->was_running);
|
||||||
hdr->compressed = bswap_32(hdr->compressed);
|
hdr->compressed = GUINT32_SWAP_LE_BE(hdr->compressed);
|
||||||
hdr->cookieOffset = bswap_32(hdr->cookieOffset);
|
hdr->cookieOffset = GUINT32_SWAP_LE_BE(hdr->cookieOffset);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user