https://github.com/bcgsc/ntCard
Raw File
Tip revision: 2040559b5e0f413bd7cfcea0ffbd2c19c2ccee24 authored by mohamadi on 17 May 2018, 22:57:14 UTC
ntCard with spaced seeds
Tip revision: 2040559
Fcontrol.cpp
#include "Fcontrol.h"
#include <fcntl.h>

/* Set the FD_CLOEXEC flag of the specified file descriptor. */
int setCloexec(int fd)
{
    int flags = fcntl(fd, F_GETFD, 0);
    if (flags == -1)
        return -1;
    flags |= FD_CLOEXEC;
    return fcntl(fd, F_SETFD, flags);
}
back to top