• Mike Rapoport's avatar
    zdtm/lib: don't close bad criu_status_in file descriptor in signal handler · d6d9d7f7
    Mike Rapoport authored
    The criu_status_in is not always used and it may be -1 when the signal
    handler closes it. With lazy-pages we hit a corner case which clobbers the
    errno value. This happens when we resume the process inside glibc syscall
    wrapper and get the signal before the page containing errno is copied. In
    this case, signal handler is invoked before the syscall return value is
    written to errno and the actual value of errno seen by the process becomes
    -EBADF because of close(-1) in the signal handler.
    
    Let's ensure that close() in signal handler does not fail to make Jenkins
    happier while the proper solution for the lazy-pages issue is found.
    Signed-off-by: 's avatarMike Rapoport <rppt@linux.vnet.ibm.com>
    Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
    d6d9d7f7
Name
Last commit
Last update
Documentation Loading commit data...
compel Loading commit data...
contrib Loading commit data...
coredump Loading commit data...
crit Loading commit data...
criu Loading commit data...
images Loading commit data...
include/common Loading commit data...
lib Loading commit data...
scripts Loading commit data...
soccr Loading commit data...
test Loading commit data...
.gitignore Loading commit data...
.mailmap Loading commit data...
.travis.yml Loading commit data...
COPYING Loading commit data...
CREDITS Loading commit data...
INSTALL.md Loading commit data...
Makefile Loading commit data...
Makefile.compel Loading commit data...
Makefile.config Loading commit data...
Makefile.install Loading commit data...
Makefile.versions Loading commit data...
README.md Loading commit data...