|
|
165f5a |
diff -up ./src/fuser.c.ori ./src/fuser.c
|
|
|
165f5a |
--- ./src/fuser.c.ori 2017-03-25 00:17:53.169339912 +0100
|
|
|
165f5a |
+++ ./src/fuser.c 2019-08-23 11:58:55.268835489 +0200
|
|
|
165f5a |
@@ -187,6 +187,9 @@ scan_procs(struct names *names_head, str
|
|
|
165f5a |
pid_t pid, my_pid;
|
|
|
165f5a |
uid_t uid;
|
|
|
165f5a |
|
|
|
165f5a |
+ if ( (ino_head == NULL) && (dev_head == NULL) )
|
|
|
165f5a |
+ return;
|
|
|
165f5a |
+
|
|
|
165f5a |
if ((topproc_dir = opendir("/proc")) == NULL) {
|
|
|
165f5a |
fprintf(stderr, _("Cannot open /proc directory: %s\n"),
|
|
|
165f5a |
strerror(errno));
|
|
|
165f5a |
@@ -1860,6 +1863,10 @@ scan_knfsd(struct names *names_head, str
|
|
|
165f5a |
char *find_space;
|
|
|
165f5a |
struct stat st;
|
|
|
165f5a |
|
|
|
165f5a |
+ if ( (ino_head == NULL) && (dev_head == NULL) )
|
|
|
165f5a |
+ return;
|
|
|
165f5a |
+
|
|
|
165f5a |
+
|
|
|
165f5a |
if ((fp = fopen(KNFSD_EXPORTS, "r")) == NULL) {
|
|
|
165f5a |
#ifdef DEBUG
|
|
|
165f5a |
printf("Cannot open %s\n", KNFSD_EXPORTS);
|
|
|
165f5a |
@@ -1906,6 +1913,10 @@ scan_mounts(struct names *names_head, st
|
|
|
165f5a |
char *find_space;
|
|
|
165f5a |
struct stat st;
|
|
|
165f5a |
|
|
|
165f5a |
+ if ( (ino_head == NULL) && (dev_head == NULL) )
|
|
|
165f5a |
+ return;
|
|
|
165f5a |
+
|
|
|
165f5a |
+
|
|
|
165f5a |
if ((fp = fopen(PROC_MOUNTS, "r")) == NULL) {
|
|
|
165f5a |
fprintf(stderr, "Cannot open %s\n", PROC_MOUNTS);
|
|
|
165f5a |
return;
|
|
|
165f5a |
@@ -1949,6 +1960,9 @@ scan_swaps(struct names *names_head, str
|
|
|
165f5a |
char *find_space;
|
|
|
165f5a |
struct stat st;
|
|
|
165f5a |
|
|
|
165f5a |
+ if ( (ino_head == NULL) && (dev_head == NULL) )
|
|
|
165f5a |
+ return;
|
|
|
165f5a |
+
|
|
|
165f5a |
if ((fp = fopen(PROC_SWAPS, "r")) == NULL) {
|
|
|
165f5a |
/*fprintf(stderr, "Cannot open %s\n", PROC_SWAPS); */
|
|
|
165f5a |
return;
|