From eaa0d7d7d23bf6cf657f0dd2e3bb02d80791498b Mon Sep 17 00:00:00 2001 From: Bill Zissimopoulos Date: Tue, 12 Apr 2022 23:26:18 +0100 Subject: [PATCH] tst: passthrough-fuse: ensure WinFsp DLL loaded --- tst/passthrough-fuse/passthrough-fuse.c | 4 ++++ tst/passthrough-fuse/winposix.h | 3 --- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/tst/passthrough-fuse/passthrough-fuse.c b/tst/passthrough-fuse/passthrough-fuse.c index 42fe8980..41943483 100644 --- a/tst/passthrough-fuse/passthrough-fuse.c +++ b/tst/passthrough-fuse/passthrough-fuse.c @@ -402,6 +402,10 @@ static void usage(void) int main(int argc, char *argv[]) { +#if defined(_WIN64) || defined(_WIN32) + WinFspLoad(); +#endif + PTFS ptfs = { 0 }; if (3 <= argc && '-' != argv[argc - 2][0] && '-' != argv[argc - 1][0]) diff --git a/tst/passthrough-fuse/winposix.h b/tst/passthrough-fuse/winposix.h index 122f56c2..df5743b2 100644 --- a/tst/passthrough-fuse/winposix.h +++ b/tst/passthrough-fuse/winposix.h @@ -81,8 +81,5 @@ struct dirent *readdir(DIR *dirp); int closedir(DIR *dirp); long WinFspLoad(void); -#undef fuse_main -#define fuse_main(argc, argv, ops, data)\ - (WinFspLoad(), fuse_main_real(argc, argv, ops, sizeof *(ops), data)) #endif