home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1992 March / Source_Code_CD-ROM_Walnut_Creek_March_1992.iso / usenet / altsrcs / 3 / 3297 / structmtab.h < prev    next >
Encoding:
C/C++ Source or Header  |  1991-05-07  |  746 b   |  31 lines

  1. #ifndef STRUCT_MTAB_H
  2. #define STRUCT_MTAB_H
  3.  
  4. #include "confmntent.h"
  5. #include "confmntult.h"
  6. #ifdef MNTENT
  7. #ifndef FILE
  8. #include <stdio.h>
  9. #endif
  10. #include <mntent.h>
  11. #else
  12. #ifdef MNTULT
  13. #include <sys/param.h>
  14. #include <sys/mount.h>
  15. #undef m_path /* dorks */
  16. #endif
  17. #include <mtab.h>
  18. #ifndef MNTMAXSTR
  19. #define MNTMAXSTR (sizeof ((struct mtab *)0)->m_path)
  20. /* A big problem here is that Ultrix 4.1, at least, defines m_path in two */
  21. /* DIFFERENT ways in sys/mount.h and mtab.h. Dorks. Fortunately, they */
  22. /* do define MNTMAXSTR in nfs/nfs_clnt.h, so we arrange to include that */
  23. /* whenever this file is used. A better solution would be to bomb DEC. */
  24. #endif
  25. #define mntent mtab
  26. #define mnt_dir m_path
  27. #define mnt_fsname m_dname
  28. #endif
  29.  
  30. #endif
  31.