getname

Returns the file specification associated with a file descriptor.

Format

#include  <unixio.h>

char *getname  (int file_desc, char *buffer, . . .
               );
Function Variants This function also has variants named _getname32 and _getname64 for use with 32-bit and 64-bit pointer sizes, respectively. See Section 1.8 for more information on using pointer-size-specific functions.

Arguments

file_desc
A file descriptor.
buffer
A pointer to a character string that is large enough to hold the file specification.
. . .
An optional argument that can be either 1 or 0. If you specify 1, the getname function returns the file specification in OpenVMS format. If you specify 0, the getname function returns the file specification in UNIX style format. If you do not specify this argument, the getname function returns the file name according to your current command-language interpreter (CLI). For more information about UNIX style file specifications, see Section 1.4.3.

Description

This function places the file specification into the area pointed to by buffer and returns that address. The area pointed to by buffer should be an array large enough to contain a fully qualified file specification (the maximum length is 256 characters).

Return Values
The address passed in the buffer argument. 
Indicates an error. 


Previous Page | Next Page | Table of Contents | Index