Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#ifdef HAVE_CONFIG_H
-#if defined (CONFIG_BROKETS)
-/* We use <config.h> instead of "config.h" so that a compilation
- using -I. -I$srcdir will use ./config.h rather than $srcdir/config.h
- (which it would do because it found this file in $srcdir). */
#include <config.h>
-#else
-#include "config.h"
-#endif
#endif
#include <stdio.h>
char *xstrdup ();
void error ();
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
#if defined (MOUNTED_GETFSSTAT) /* __alpha running OSF_1 */
# include <sys/mount.h>
# include <sys/fs_types.h>
#endif
#ifdef MOUNTED_GETMNT /* Ultrix. */
-#include <sys/param.h>
#include <sys/mount.h>
#include <sys/fs_types.h>
#endif
}
#endif /* MOUNTED_GETMNTENT1. */
-#ifdef MOUNTED_GETMNTINFO /* 4.4BSD. */
+#if defined (MOUNTED_GETMNTINFO) && !defined (__NetBSD__)
static char *
fstype_to_string (t)
short t;
me = (struct mount_entry *) xmalloc (sizeof (struct mount_entry));
me->me_devname = xstrdup (fsp->f_mntfromname);
me->me_mountdir = xstrdup (fsp->f_mntonname);
+#ifdef __NetBSD__
+ me->me_type = xstrdup (fsp->f_fstypename);
+#else
me->me_type = fstype_to_string (fsp->f_type);
+#endif
me->me_dev = -1; /* Magic; means not known yet. */
me->me_next = NULL;