unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (4.2BSD)
Page:
Section:
Apropos / Subsearch:
optional field

GETFSENT(3X)                                                      GETFSENT(3X)



NAME
       getfsent,  getfsspec,  getfsfile,  getfstype,  setfsent, endfsent - get
       file system descriptor file entry

SYNOPSIS
       #include <&lt;fstab.h>&gt;

       struct fstab *getfsent()

       struct fstab *getfsspec(spec)
       char *spec;

       struct fstab *getfsfile(file)
       char *file;

       struct fstab *getfstype(type)
       char *type;

       int setfsent()

       int endfsent()

DESCRIPTION
       Getfsent, getfsspec, getfstype, and getfsfile each return a pointer  to
       an object with the following structure containing the broken-out fields
       of a line in the file system description file, &lt;fstab.h&gt;.

              struct fstab{
                   char *fs_spec;
                   char *fs_file;
                   char *fs_type;
                   int  fs_freq;
                   int  fs_passno;
              };

       The fields have meanings described in fstab(5).

       Getfsent reads the next line of the file, opening the  file  if  neces-
       sary.

       Setfsent opens and rewinds the file.

       Endfsent closes the file.

       Getfsspec  and  getfsfile sequentially search from the beginning of the
       file until a matching special file name or file  system  file  name  is
       found,  or until EOF is encountered.  Getfstype does likewise, matching
       on the file system type field.

FILES
       /etc/fstab

SEE ALSO
       fstab(5)

DIAGNOSTICS
       Null pointer (0) returned on EOF or error.

BUGS
       All information is contained in a static area so it must be  copied  if
       it is to be saved.



4th Berkeley Distribution       19 January 1983                   GETFSENT(3X)