Try to fix EBADF