insque(3) — Subroutines
OSF
NAME
insque, remque − Inserts or removes an element in a queue
LIBRARY
Standard C Library (libc.a)
SYNOPSIS
struct qelem [
struct qelem ∗q_forw;
struct qelem ∗q_back;
char q_data[ ];
]; insque (
struct qelem ∗element,
struct qelem ∗pred ); remque (
struct qelem ∗element );
PARAMETERS
predPoints to the element in the queue immediately before the element to be inserted or deleted.
elementPoints to the element in the queue immediately after the element to be inserted or deleted.
DESCRIPTION
The insque() and remque() functions manipulate queues built from double-linked lists. Each element in the queue must be in the form of a qelem structure. The q_forw and q_back elements of that structure must point to the elements in the queue immediately before and after the element to be inserted or deleted.
The insque() function inserts the element pointed to by the element parameter into a queue immediately after the element pointed to by the pred parameter.
The remque() function removes the element defined by the element parameter from a queue.