aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/smbfs/smbutil/dumptree.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/smbfs/smbutil/dumptree.c')
-rw-r--r--contrib/smbfs/smbutil/dumptree.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/contrib/smbfs/smbutil/dumptree.c b/contrib/smbfs/smbutil/dumptree.c
index 3bf86ff69ae9..7d06142c3bd1 100644
--- a/contrib/smbfs/smbutil/dumptree.c
+++ b/contrib/smbfs/smbutil/dumptree.c
@@ -4,6 +4,10 @@
#include <string.h>
#include <unistd.h>
#include <stdlib.h>
+#ifdef APPLE
+#include <err.h>
+#include <sysexits.h>
+#endif
#include <netsmb/smb_lib.h>
#include <netsmb/smb_conn.h>
@@ -102,6 +106,10 @@ cmd_dumptree(int argc, char *argv[])
int *itype;
printf("SMB connections:\n");
+#ifdef APPLE
+ if (loadsmbvfs())
+ errx(EX_OSERR, "SMB filesystem is not available");
+#endif
p = smb_dumptree();
if (p == NULL) {
printf("None\n");