VMS Help  —  CRTL  lstat
    Retrieves information about the specified file.

    This function is supported on OpenVMS Integrity servers and
    Alpha only.

    Format

      #include  <sys/stat.h>

      int lstat  (const char *restrict file_path, struct stat
                 *restrict user_buffer);

1  –  Arguments

 file_path

    The name of the file for which you want to retrieve information.

 user_buffer

    The stat structure in which information is returned.

2  –  Description

    The lstat function retrieves information about the specified file
    (file_path). If the file is a symbolic link, information about
    the link itself is returned (in contrast to stat, which returns
    information about the file that the symbolic link points to).

    See also symlink, unlink, readlink, realpath, and lchown.

3  –  Return Values

    0                  Successful completion.
    -1                 Indicates an error. errno is set to any errno
                       value returned by stat.
Close Help