From: Kern Sibbald Date: Fri, 25 May 2018 08:35:22 +0000 (+0200) Subject: Apply patch from Leo to fix bug 2192 X-Git-Tag: Release-9.0.8~9 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e63a27cc1c2e195ad44b00ebdf34b4f758f07b02;p=bacula%2Fbacula Apply patch from Leo to fix bug 2192 --- diff --git a/bacula/src/findlib/fstype.c b/bacula/src/findlib/fstype.c index 9478463fb2..07cf943431 100644 --- a/bacula/src/findlib/fstype.c +++ b/bacula/src/findlib/fstype.c @@ -93,6 +93,7 @@ void add_mtab_item(void *user_ctx, struct stat *st, const char *fstype, */ #if defined(HAVE_DARWIN_OS) \ || defined(HAVE_FREEBSD_OS ) \ + || defined(HAVE_KFREEBSD_OS ) \ || defined(HAVE_OPENBSD_OS) #include @@ -356,7 +357,10 @@ bool fstype(FF_PKT *ff_pkt, char *fs, int fslen) /* Read mtab entries */ bool read_mtab(mtab_handler_t *mtab_handler, void *user_ctx) -{ +{ +/* Debian stretch GNU/KFreeBSD has both getmntinfo and getmntent, but + only the first seems to work, so we skip over getmntent in this case */ +#ifndef HAVE_KFREEBSD_OS #ifdef HAVE_GETMNTENT FILE *mntfp; struct stat st; @@ -409,6 +413,7 @@ bool read_mtab(mtab_handler_t *mtab_handler, void *user_ctx) #endif #endif /* HAVE_GETMNTENT */ +#endif /* HAVE_KFREEBSD_OS */ #ifdef HAVE_GETMNTINFO struct stat st;