$NetBSD: patch-ae,v 1.4 2004/11/19 12:35:22 sketch Exp $ --- src/FileSystem.c++.orig 2003-01-18 14:18:12.000000000 +0000 +++ src/FileSystem.c++ 2004-11-08 15:39:34.558377000 +0000 @@ -22,14 +22,20 @@ #include "FileSystem.h" -#include +#include "fam-mntent.h" #include #include "Event.h" +#if defined(HAVE_SYS_MNTTAB_H) +FileSystem::FileSystem(const mnttab& mnt) + : mydir (strcpy(new char[strlen(mnt.mnt_mountp) + 1], mnt.mnt_mountp)), + myfsname(strcpy(new char[strlen(mnt.mnt_special) + 1], mnt.mnt_special)) +#else FileSystem::FileSystem(const mntent& mnt) : mydir (strcpy(new char[strlen(mnt.mnt_dir ) + 1], mnt.mnt_dir )), myfsname(strcpy(new char[strlen(mnt.mnt_fsname) + 1], mnt.mnt_fsname)) +#endif { } FileSystem::~FileSystem() @@ -40,9 +46,15 @@ } bool +#if defined(HAVE_SYS_MNTTAB_H) +FileSystem::matches(const mnttab& mnt) const +{ + return !strcmp(mydir, mnt.mnt_mountp) && !strcmp(myfsname, mnt.mnt_special); +#else FileSystem::matches(const mntent& mnt) const { return !strcmp(mydir, mnt.mnt_dir) && !strcmp(myfsname, mnt.mnt_fsname); +#endif } void