mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-29 04:50:26 +00:00
criu/files: Fix wait_fds_event() for 64 bit platforms
The htole64() function returns a 64 bit value. This is stored in a 32 bit integer in wait_fds_event() which results in 0 for big-endian 64 bit platforms. The fuxtex() system call also requires 32 bit values. Fix this and use htole32() also for 64 bit platforms. Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
parent
624aa178dc
commit
3ed5c2f0ee
1 changed files with 1 additions and 4 deletions
|
|
@ -178,11 +178,8 @@ void wait_fds_event(void)
|
|||
{
|
||||
futex_t *f = ¤t->task_st;
|
||||
int value;
|
||||
#if BITS_PER_LONG == 64
|
||||
value = htole64(FDS_EVENT);
|
||||
#else
|
||||
|
||||
value = htole32(FDS_EVENT);
|
||||
#endif
|
||||
futex_wait_if_cond(f, value, &);
|
||||
clear_fds_event();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue