[Previous]
[Contents]
[Next]

qnx_prefix_query()

query the pathname prefix tree

Synopsis:

#include <sys/prfx.h>
int qnx_prefix_query( nid_t nid, char *path,
                      char *buffer, int len );

Description:

The qnx_prefix_query() function returns the prefix tree below path on node nid, in buffer. The data in buffer is returned as a string and limited to len characters. If path is "" then the entire prefix string is returned in the form:

[prefix=string[:prefix=string] ... ]

For example,

  /=//1/:/dev=8,a

where the square brackets aren't present, but indicate that the item enclosed is optional. The string is either an alias, such as /=//1/, or a resource manager mapping, such as /dev=8,a, where 8 is the process id, and a is the unit number.

If path isn't "", then a list of directories in the prefix tree immediately below the path is returned in the following form:

[dirname[\ndirname] ... ]

For example, where path = "/":

  dev

Returns:

0
Success
-1
An error occurred. errno is set to indicate the error.

Errors:

This function may set errno to any of the values listed for qnx_vc_attach().

Examples:

See qnx_prefix_attach().

Classification:

QNX

Safety:
Interrupt handler No
Signal handler Yes, but modifies errno
Thread Yes

See also:

errno, qnx_prefix_attach(), qnx_prefix_detach(), qnx_vc_attach()


[Previous]
[Contents]
[Next]