backports: Add g_steal_fd, from GLib >= 2.70
This is essentially the same as glnx_steal_fd, so make glnx_steal_fd an
alias for it.
The unit test is taken from GLib, slightly modified to avoid g_close()
and also test the old name glnx_steal_fd().
Signed-off-by:
Simon McVittie <smcv@collabora.com>
Showing
- glnx-backports.h 11 additions, 0 deletionsglnx-backports.h
- glnx-dirfd.c 2 additions, 2 deletionsglnx-dirfd.c
- glnx-fdio.c 3 additions, 3 deletionsglnx-fdio.c
- glnx-local-alloc.h 6 additions, 9 deletionsglnx-local-alloc.h
- glnx-lockfile.c 1 addition, 1 deletionglnx-lockfile.c
- tests/test-libglnx-backports.c 39 additions, 0 deletionstests/test-libglnx-backports.c
Please register or sign in to comment