]> xenbits.xensource.com Git - libvirt.git/commit
virmockstathelpers: Load aliases for 64-bit time
authorMichal Privoznik <mprivozn@redhat.com>
Fri, 18 Nov 2022 16:13:22 +0000 (17:13 +0100)
committerMichal Privoznik <mprivozn@redhat.com>
Mon, 21 Nov 2022 14:49:36 +0000 (15:49 +0100)
commitb09441b1c5a9f3d705e939f9b5f4a2bcbcaec4c3
tree24e1762a3290c229592297481b5b08c9cc9cb587
parent6f80761c08b05bfa4370f54a86ef6bb26f134279
virmockstathelpers: Load aliases for 64-bit time

On 32-bit arches, it's possible not only to request
-D_FILE_OFFSET_BITS=64 (which is always done with meson) but also
-D_TIME_BITS=64. With glibc, both of these affect what variant of
stat() or lstat() is called. With 64 bit time it's:
__stat64_time64() or __lstat64_time64(), respectively.

Fortunately, no other variant (__xstat(), __xstat64()) has
_time64 alternative and thus does not need similar treatment.

Similarly, musl is not affected by this.

Resolves: https://gitlab.com/libvirt/libvirt/-/issues/404
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
tests/virmockstathelpers.c