summaryrefslogtreecommitdiffstats
path: root/support
diff options
context:
space:
mode:
Diffstat (limited to 'support')
-rw-r--r--support/export/xtab.c31
-rw-r--r--support/include/exportfs.h4
-rw-r--r--support/include/nfslib.h9
3 files changed, 3 insertions, 41 deletions
diff --git a/support/export/xtab.c b/support/export/xtab.c
index e953071..10d9dbc 100644
--- a/support/export/xtab.c
+++ b/support/export/xtab.c
@@ -1,7 +1,7 @@
/*
* support/export/xtab.c
*
- * Interface to the xtab file.
+ * Interface to the etab/exports file.
*
* Copyright (C) 1995, 1996 Olaf Kirch <okir@monad.swb.de>
*/
@@ -29,7 +29,6 @@ xtab_read(char *xtab, char *lockfn, int is_export)
{
/* is_export == 0 => reading /proc/fs/nfs/exports - we know these things are exported to kernel
* is_export == 1 => reading /var/lib/nfs/etab - these things are allowed to be exported
- * is_export == 2 => reading /var/lib/nfs/xtab - these things might be known to kernel
*/
struct exportent *xp;
nfs_export *exp;
@@ -55,9 +54,6 @@ xtab_read(char *xtab, char *lockfn, int is_export)
if ((xp->e_flags & NFSEXP_FSID) && xp->e_fsid == 0)
v4root_needed = 0;
break;
- case 2:
- exp->m_exported = -1;/* may be exported */
- break;
}
}
endexportent();
@@ -79,7 +75,7 @@ xtab_mount_read(void)
return xtab_read(_PATH_PROC_EXPORTS_ALT,
_PATH_PROC_EXPORTS_ALT, 0);
} else
- return xtab_read(_PATH_XTAB, _PATH_XTABLCK, 2);
+ return 0;
}
int
@@ -135,29 +131,6 @@ xtab_export_write()
return xtab_write(_PATH_ETAB, _PATH_ETABTMP, _PATH_ETABLCK, 1);
}
-int
-xtab_mount_write()
-{
- return xtab_write(_PATH_XTAB, _PATH_XTABTMP, _PATH_XTABLCK, 0);
-}
-
-void
-xtab_append(nfs_export *exp)
-{
- struct exportent xe;
- int lockid;
-
- if ((lockid = xflock(_PATH_XTABLCK, "w")) < 0)
- return;
- setexportent(_PATH_XTAB, "a");
- xe = exp->m_export;
- xe.e_hostname = exp->m_client->m_hostname;
- putexportent(&xe);
- endexportent();
- xfunlock(lockid);
- exp->m_xtabent = 1;
-}
-
/*
* rename newfile onto oldfile unless
* they are identical
diff --git a/support/include/exportfs.h b/support/include/exportfs.h
index 32d4fe9..08ef30a 100644
--- a/support/include/exportfs.h
+++ b/support/include/exportfs.h
@@ -96,7 +96,7 @@ typedef struct mexport {
struct mexport * m_next;
struct mclient * m_client;
struct exportent m_export;
- int m_exported; /* known to knfsd. -1 means not sure */
+ int m_exported; /* known to knfsd. */
int m_xtabent : 1, /* xtab entry exists */
m_mayexport: 1, /* derived from xtabbed */
m_changed : 1, /* options (may) have changed */
@@ -150,9 +150,7 @@ int export_unexport(nfs_export *);
int xtab_mount_read(void);
int xtab_export_read(void);
-int xtab_mount_write(void);
int xtab_export_write(void);
-void xtab_append(nfs_export *);
int secinfo_addflavor(struct flav_info *, struct exportent *);
diff --git a/support/include/nfslib.h b/support/include/nfslib.h
index ddd71ac..777f398 100644
--- a/support/include/nfslib.h
+++ b/support/include/nfslib.h
@@ -35,15 +35,6 @@
#ifndef _PATH_IDMAPDCONF
#define _PATH_IDMAPDCONF "/etc/idmapd.conf"
#endif
-#ifndef _PATH_XTAB
-#define _PATH_XTAB NFS_STATEDIR "/xtab"
-#endif
-#ifndef _PATH_XTABTMP
-#define _PATH_XTABTMP NFS_STATEDIR "/xtab.tmp"
-#endif
-#ifndef _PATH_XTABLCK
-#define _PATH_XTABLCK NFS_STATEDIR "/.xtab.lock"
-#endif
#ifndef _PATH_ETAB
#define _PATH_ETAB NFS_STATEDIR "/etab"
#endif