From 7ce4e2572d80a0539735bbe0464e3c315af1f301 Mon Sep 17 00:00:00 2001 From: Reuben Thomas Date: Mon, 10 Dec 2007 17:01:43 +0000 Subject: Don't try to stop mounting on a non-empty mount point. --- plpnfsd/mp_main.c | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'plpnfsd/mp_main.c') diff --git a/plpnfsd/mp_main.c b/plpnfsd/mp_main.c index 172e29a..e491ff4 100644 --- a/plpnfsd/mp_main.c +++ b/plpnfsd/mp_main.c @@ -180,22 +180,6 @@ mp_main(int verbose, char *dir, char *user) if (debug) printf("plpnfsd: version %s, mounting on %s ...\n", VERSION, dir); - /* Check if mountdir is empty (or else you can overmount e.g /etc) - It is done here, because exit hangs, if hardware flowcontrol is - not present. Bugreport Nov 28 1996 by Olaf Flebbe */ - if (!(dirp = opendir(dir))) { - perror(dir); - return 1; - } - i = 0; - while ((diep = readdir(dirp)) != 0) - if (strcmp(diep->d_name, ".") && strcmp(diep->d_name, "..")) - i++; - closedir(dirp); - if (i) { - fprintf(stderr, "Sorry, directory %s is not empty, exiting.\n", dir); - return 1; - } openlog("plpnfsd", LOG_PID|LOG_CONS, LOG_DAEMON); rp = get_nam(""); inode2fh(rp->inode, root_fh.data); -- cgit v1.2.3