Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ cd_suf(3X) — UnixWare 2.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

cddevsuppl(1M)

cdsuf(1M)

dir(4CDFS)






       cd_suf(3X)                                                cd_suf(3X)


       NAME
             cd_suf - read the cdfs System Use Field from the specified
             System Use Area

       SYNOPSIS
             cc [flag . . . ] file . . . -lcdfs -lgen [library] . . .
             #include <sys/cdrom.h>
             int cd_suf(const char *path, int fsec, char *signature, int index,
                   char *buf, int buflen);

       DESCRIPTION
             cd_suf reads a System Use Field of the System Use Area
             associated with a File Section of a file or directory,
             following any continuation fields that may be present.  A
             continuation field is a System Use Field that extends the
             System Use Area so more System Use Fields can be stored.
             Continuation fields are defined in the System Use Sharing
             Protocol specification.  The System Use Area may be used by
             the manufacturer to record additional information about files
             and directories, such as the POSIX file system information.

             path      Points to a file or directory within the CD-ROM file
                       hierarchy.

             fsec      Identifies the File Section of that file to be used.
                       The numbering starts with 1.  If fsec is set to -1,
                       the System Use Area of the last File Section of that
                       file is assumed.

             signature The 2-byte signature word of the requested System
                       Use Field.  See cdfs-specific dir(4CDFS) for a list
                       of the known valid System Use Field values.

             index     Specifies the occurrence number of signature to
                       return.  If signature is NULL, the index'th
                       occurrence of the System Use Field is returned,
                       starting from the beginning of the SUSP portion of
                       System Use Area.  Otherwise, the index'th occurrence
                       of signature is returned.  The index number of the
                       first System Use Field of any signature is 1.

             buf       Specifies the address of the buffer in which to
                       place the System Use Field.





                           Copyright 1994 Novell, Inc.               Page 1













      cd_suf(3X)                                                cd_suf(3X)


            buflen    Specifies the length of the buffer in which to place
                      the System Use Field.

         Return Values
            On success, cd_suf returns the number of bytes placed in buf.
            If the signature field is not found, zero is returned.  On
            failure, cd_suf returns -1 and sets errno to indicate the
            error.

         Errors
            EACCES    Search permission for a component of the path prefix
                      is denied.

            EACCES    Read permission on the file or directory pointed to
                      by path is denied.

            EFAULT    The address of buf, signature or path is invalid.

            EINTR     A signal was caught during the cd_suf function.

            EINVAL    The value of fsec, index or buflen is invalid.

            EINVAL    The path argument points to a file or directory that
                      is not within the CD-ROM file hierarchy.

            EMFILE    Too many file descriptors are currently open in the
                      calling process.

            ENAMETOOLONG
                      The length of the path string exceeds MAXPATHLEN.

            ENAMETOOLONG
                      A pathname component is longer than MAXNAMELEN while
                      _POSIX_NO_TRUNC is in effect.

            ENFILE    The system file table is full.

            ENODEV    The Volume containing the File Section indicated by
                      fsec is not mounted.

            ENOENT    A component of path does not exist.

            ENOENT    The path argument points to an empty string.





                          Copyright 1994 Novell, Inc.               Page 2













       cd_suf(3X)                                                cd_suf(3X)


             ENOENT    The File Section indicated by fsec has no System Use
                       Area.

             ENOTDIR   A component of the path prefix is not a directory.

             ENXIO     The CD-ROM is not in the drive.

             ENXIO     A read error occurred.

       REFERENCES
             cddevsuppl(1M), cdsuf(1M), cdfs-specific dir(4CDFS)
             Rock Ridge Interchange Protocol and the System Use Sharing
             Protocol from the Rock Ridge Technical Working Group



































                           Copyright 1994 Novell, Inc.               Page 3








Typewritten Software • bear@typewritten.org • Edmonds, WA 98026