Il 03/10/2014 19:47, Dr. David Alan Gilbert (git) ha scritto:
> +#ifndef WIN32
> +    if (rd) {
> +        how = SHUT_RD;
> +    }
> +
> +    if (wr) {
> +        how = rd ? SHUT_RDWR : SHUT_WR;
> +    }
> +
> +#else
> +    /* Untested */
> +    if (rd) {
> +        how = SD_RECEIVE;
> +    }
> +
> +    if (wr) {
> +        how = rd ? SD_BOTH : SD_SEND;
> +    }
> +
> +#endif
> +


These are the same on Windows and non-Windows actually.  Just #define
SHUT_* to 0/1/2 and avoid the wrapper.

Paolo

Reply via email to