Reference Guide

ZCOM C I/F Library Routines
MAKEZLUNAME (3X)
Chapter 4160
The libraries libzcom_c.a and libpthread.a must be linked into the calling
program by giving the options “-lzcom_c -lpthread” to cc(1) or ld(1).
Threads
Considerations
This routine may be called from a multi-threaded application using the
POSIX (1003.1c) kernel threads API package. This routine has the
following characteristics when called by a multi-threaded application:
See the WARNING section below for more information on using this
routine in a multi-threaded application.
PAR AMETER S
RETURN VALUE Routine makezluname returns a null-terminated character string,
which consists of the user-supplied name parameter merged with the
TTY name suffix.
WARNING If two different programs call this routine with the same name
parameter and from the same TTY, the same ZLU name will be
returned.This implies that if multiple copies of a program are
run from the same TTY, they will all get the same ZLU name. If
they are run from different terminals, different ZLU names will
be returned.
console MYnsole Trailing part of TTY name is used.
TTY
Name
Returned
Name
Comment
cancellation point Thread cancellation can occur when a thread
calls this routine.
async-cancel unsafe The calling threads cancelability type must be
PTHREAD_CANCEL_DEFERRED if
cancellation is enabled.
async-signal unsafe It cannot be called from a signal handler.
fork unsafe It cannot be called by a child process after
fork(2) but before exec(2).
name Name to be merged with TTY suffix.