diff options
author | Alejandro Colomar <colomar.6.4.3@gmail.com> | 2020-10-25 10:36:48 +0100 |
---|---|---|
committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2020-10-25 10:42:35 +0100 |
commit | cf5b6a7745ddaaa60f4b285796d69e59b148c19f (patch) | |
tree | 719698bbb0ccaed02f964f30c45811c2848da3fc | |
parent | 7b8d4bbf32a9182b7da8a070484d368f56b831a1 (diff) | |
download | man-pages-cf5b6a7745ddaaa60f4b285796d69e59b148c19f.tar.gz |
tailq.3: Copy and adapt code from queue.3
Signed-off-by: Alejandro Colomar <colomar.6.4.3@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
-rw-r--r-- | man3/tailq.3 | 26 |
1 files changed, 8 insertions, 18 deletions
diff --git a/man3/tailq.3 b/man3/tailq.3 index 28a7ac509f..6f2466cbf0 100644 --- a/man3/tailq.3 +++ b/man3/tailq.3 @@ -89,26 +89,14 @@ In the macro definitions, .Fa TYPE is the name of a user defined structure, that must contain a field of type -.Li SLIST_ENTRY , -.Li STAILQ_ENTRY , -.Li LIST_ENTRY , .Li TAILQ_ENTRY , -or -.Li CIRCLEQ_ENTRY , named .Fa NAME . The argument .Fa HEADNAME is the name of a user defined structure that must be declared -using the macros -.Li SLIST_HEAD , -.Li STAILQ_HEAD , -.Li LIST_HEAD , -.Li TAILQ_HEAD , -or -.Li CIRCLEQ_HEAD . -See the examples below for further explanation of how these -macros are used. +using the macro +.Li TAILQ_HEAD . .Ss Tail queues A tail queue is headed by a structure defined by the .Nm TAILQ_HEAD @@ -317,10 +305,12 @@ from the tail queue. .\" .Fa head1 .\" and .\" .Fa head2 . -.Pp -See the EXAMPLES section below for an example program using a tail queue. .SH RETURN VALUE .SH CONFORMING TO +Not in POSIX.1, POSIX.1-2001 or POSIX.1-2008. +Present on the BSDs. +(TAILQ functions first appeared in +.Bx 4.4 ). .SH BUGS .SH EXAMPLES .Ss Tail queue example @@ -340,9 +330,9 @@ TAILQ_HEAD(tailhead, entry); int main(void) { - struct entry *n1, *n2, *n3, *np; + struct entry *n1, *n2, *n3, *np; struct tailhead head; /* Tail queue head. */ - int i; + int i; TAILQ_INIT(&head); /* Initialize the queue. */ |