[Bug 95331] fcntl.2 + sigaction.2 + signal.7 need further information about use of a SA_SIGINFO signal handler that uses si->si_fd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



https://bugzilla.kernel.org/show_bug.cgi?id=95331

--- Comment #16 from Jason Vas Dias <jason.vas.dias@xxxxxxxxx> ---
Since currently ONLY open() already waits for readers to connect :

    case FMODE_WRITE:
    /*
     *  O_WRONLY
     *  POSIX.1 says that O_NONBLOCK means return -1 with
     *  errno=ENXIO when there is no process reading the FIFO.
     */
        ret = -ENXIO;
        if (!is_pipe && (filp->f_flags & O_NONBLOCK) && !pipe->readers)
            goto err;

        pipe->w_counter++;
        if (!pipe->writers++)
            wake_up_partner(pipe);

        if (!is_pipe && !pipe->readers) {
            if (wait_for_partner(pipe, &pipe->r_counter))
                goto err_wr;
        }
        break;


I think if O_ASYNC is set and O_NONBLOCK is NOT set , once ONE sigpipe
or EPIPE has been generated, then the next write should block  for  pipes
marked with sigio_on_write_enabled , and also readers should generate 
the SIGIO events BEFORE they are about to read. I guess such changes
might take a long time to become accepted ...
But which paragraphs of which standard are meant to apply to this 
situtation ? Where is it specified what SHOULD happen in these cases ?

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux