resmgr_pathname()
QNX SDP8.0C Library ReferenceAPIDeveloper
Return the pathname associated with an ID
Synopsis:
#include <sys/iofunc.h>
#include <sys/resmgr.h>
int resmgr_pathname( int id,
unsigned flags,
char* path,
int maxbuf );
Arguments:
- id
- The link ID that resmgr_attach() returned.
- flags
- Use 0.
- path
- A pointer to a buffer where the function can store the path name.
- maxbuf
- The size of the buffer.
Library:
libc
Use the -l c option to qcc to link against this library. This library is usually included automatically.
Description:
The resmgr_pathname() function returns the pathname associated with an id that's returned from resmgr_attach(), it's also the ctp->id value of all the resmgr callout functions.
If the id was obtained from calling resmgr_attach() with _RESMGR_FLAG_DIR specified, then the path name includes a trailing slash.
Returns:
The length of the path, including the terminating NUL character, or -1 if an error occurs (errno is set).
Errors:
- EFAULT
- A fault occurred in a server's address space when it tried to access the caller's message buffers.
- ESRCH
- The thread indicated by ctp->rcvid doesn't exist or its connection is detached.
- ESRVRFAULT
- A fault occurred when the kernel tried to access the buffers provided.
Classification:
Safety: | |
---|---|
Cancellation point | No |
Signal handler | Yes |
Thread | Yes |
Page updated: