Changeset e7e6484 for tests


Ignore:
Timestamp:
2017-03-12T04:27:59Z (7 years ago)
Author:
dx <dx@…>
Branches:
master
Children:
c9e9c9c
Parents:
16e4a9f
git-author:
Anthony Molinaro <anthonym@…> (13-02-17 21:46:42)
git-committer:
dx <dx@…> (12-03-17 04:27:59)
Message:

The protocol argument to socketpair was incorrect.

For some reason the protocol was being set to PF_UNIX which is
incorrect. According to the man pages and other sources (like Stevens
Unix Network Programming), the protocol should be '0' which will
use the default for the given domain. This appears to actually
work under Linux (which appears to allow 0 or 1 as the protocol without
error), but fails under Mac OSX (which only allows 0).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/check.c

    r16e4a9f re7e6484  
    1414        int sock[2];
    1515
    16         if (socketpair(AF_UNIX, SOCK_STREAM, PF_UNIX, sock) < 0) {
     16        if (socketpair(AF_UNIX, SOCK_STREAM, 0, sock) < 0) {
    1717                perror("socketpair");
    1818                return FALSE;
Note: See TracChangeset for help on using the changeset viewer.