This commit is contained in:
Benson Chu 2023-05-08 04:49:22 -05:00
parent 171a9c1c34
commit d4f4490a3f

View file

@ -520,7 +520,7 @@ int
process_output_buffers_ready_copy_fd_set(struct fd_set * destination)
{
process_output_ready_fds_mutex_lock();
FD_COPY(&process_output_buffers_ready_fds, destination);
memcpy(( destination ), ( &process_output_buffers_ready_fds ), sizeof( fd_set ));
int count = process_output_buffers_ready_count;
process_output_ready_fds_mutex_unlock();
return count;
@ -888,7 +888,7 @@ process_output_producer_thread(void * args)
struct timespec * select_timeout = readingCount == 0 ? NULL : &no_timeout;
pselect(maxFd + 1, &fds, NULL, NULL, select_timeout, NULL);
FD_COPY(&fds, &ready_fds);
memcpy(( &ready_fds ), ( &fds ), sizeof( fd_set ));
}
return NULL;
}