Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ pipe(S) — OpenDesktop Software Development System 3.0.0

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

read(S)

sh(C)

write(S)

fcntl(S)

sysi86(S)

pipe(ADM)


 pipe(S)                        6 January 1993                        pipe(S)


 Name

    pipe - create an interprocess channel

 Syntax


    cc ... -lc


    int pipe (fildes)
    int fildes[2];


 Description

    The pipe system call creates an I/O mechanism called a pipe and returns
    two file descriptors, fildes[0] and fildes[1].  fildes[0] is opened for
    reading and fildes[1] is opened for writing.

    Up to 5120 bytes of data are buffered by the pipe before the writing pro-
    cess is blocked.  A read-only file descriptor fildes[0] accesses the data
    written to fildes[1] on a first-in-first-out (FIFO) basis.

    The pipe system call fails if:


    [EMFILE]       The current process has reached the limit of open files.

    [ENFILE]       The system file table is full.

    [ENODEV]       There is no pipe filesystem.

 Diagnostics

    Upon successful completion, a value of 0 is returned.  Otherwise, a value
    of -1 is returned, and errno is set to indicate the error.

 See also

    read(S), sh(C), write(S), fcntl(S), sysi86(S), pipe(ADM)

 Standards conformance

    pipe is conformant with:
    AT&T SVID Issue 2;
    X/Open Portability Guide, Issue 3, 1989;
    IEEE POSIX Std 1003.1-1990 System Application Program Interface (API) [C
    Language] (ISO/IEC 9945-1);
    and NIST FIPS 151-1.


Typewritten Software • bear@typewritten.org • Edmonds, WA 98026