Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getdprop(2) — SunOS 0.4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

GETDPROP(2)  —  System Interface Manual — System Calls

NAME

getdprop − get properties of a descriptor

SYNOPSIS

#include <descrip.h>

getdprop(d, dpp)
int d;
struct dprop ∗dpp;

DESCRIPTION

The properties associated with the descriptor d are returned in the structure pointed to by dpp. This structure is of the form

struct dprop {
intdp_type;/∗ see list below ∗/
intdp_protocol;/∗ which of several ∗/
intdp_version;/∗ version of protocol ∗/
};
#defineDTYPE_CONTEXT0/∗ namin context ∗/
#defineDTYPE_FILE   1/∗ open file ∗/
#defineDTYPE_DIR   2/∗ directory being read as file ∗/
#defineDTYPE_DOMAIN 3/∗ communications domain ∗/
#defineDTYPE_SOCKET 4/∗ ipc endpoint ∗/
#defineDTYPE_TTY    5/∗ terminal ∗/
#defineDTYPE_STRDEV 6/∗ structured device ∗/
#defineDTYPE_UNSTRDEV7/∗ unstructured device ∗/
#defineDTYPE_PROCESS 8/∗ process control handle ∗/
#defineDTYPE_CHILD   9/∗ handle for returning child status ∗/
#defineDTYPE_KERNEL  10/∗ handle to operating system ∗/

NOTES

Each type supports a set of operations; some operations such as reading and writing are common to several abstractions, while others are unique. 

SEE ALSO

4.2BSD System Manual

DIAGNOSTICS

−1 is returned if the descriptor supplied is invalid. 

Sun System Release 0.3

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