rem: sig_action.sa_handler = SIG_IGN;
add: sig_action.sa_handler = &handle_sigpipe;
context: createConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/{    WMConnection *cPtr;    struct sigaction sig_action;    cPtr = wmalloc(sizeof(WMConnection));    wretain(cPtr);    memset(cPtr, 0, sizeof(WMConnection));    fcntl(sock, F_SETFD, FD_CLOEXEC); /* by default close on exec */    cPtr->sock = sock;    cPtr->openTimeout.timeout = OpenTimeout;    cPtr->openTimeout.handler = NULL;    cPtr->sendTimeout.timeout = DefaultTimeout;    cPtr->sendTimeout.handler = NULL;    cPtr->closeOnRelease = closeOnRelease;    cPtr->outputQueue =        WMCreateArrayWithDestructor(16, (WMFreeDataProc*)WMReleaseData);    cPtr->state = WCNotConnected;    cPtr->timeoutState = WCTNone;    /* ignore dead pipe */    if (!SigInitialized) {        sig_action.sa_handler = SIG_IGN;        sig_action.sa_flags = SA_RESTART;        sigaction(SIGPIPE, &sig_action, NULL);        SigInitialized = True;    }    return cPtr;}