hpux man page for stdipc

Query: stdipc

OS: hpux

Section: 3c

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

ftok(3C)																  ftok(3C)

NAME
ftok() - create interprocess communication identifier
SYNOPSIS
DESCRIPTION
All interprocess communication facilities require the user to supply a key to be used by the and system calls to obtain interprocess commu- nication identifiers (see msgget(2), semget(2), and shmget(2)). returns a key based on path and id that is usable in subsequent and system calls. The parameters for the function are as follows: path must be the path name of an existing file that is accessible to the process. id is a character that uniquely identifies a project. This means that only the low order 8-bits of id are signifi- cant. Note that returns the same key for linked files when called with the same id and that it returns differ- ent keys when called with the same file name but different ids.
RETURN VALUE
returns if path does not exist or if it is not accessible to the process.
EXAMPLES
The following call to returns a key associated with the file myfile and id
WARNINGS
If the file whose path is passed to is removed when keys still refer to the file, future calls to with the same path and id will return an error. If the same file is recreated, is likely to return a different key than it did the original time it was called.
SEE ALSO
intro(2), msgget(2), semget(2), shmget(2), thread_safety(5). ftok(3C)
Related Man Pages
ftok(3p) - centos
ftok(3c) - opensolaris
ftok(3) - mojave
ftok(3) - ultrix
ftok(3c) - sunos
Similar Topics in the Unix Linux Community
Problem with msgget()
How do manipulate file path and names
wildcards in path
ftok system call