typedef union epoll_data
{
  void        *ptr;
  int          fd;
  __uint32_t   u32;
  __uint64_t   u64;
} epoll_data_t;

Here int and __uint32_t are 4 bytes,while the others are 8 bytes.

When we set fd to an int,does it lie on the first 4 bytes or the last 4 bytes,or does it depend on endianness?

Some reason is appreciated.

Edit
Report