X-Git-Url: http://git.sven.stormbind.net/?p=sven%2Ffuse-exfat.git;a=blobdiff_plain;f=fuse%2Fmain.c;h=a8134276c8bf4eaa1cba07b7b779dec965ec5b42;hp=fe5666beabab1fe0657ef670aa7ed357a8829fc3;hb=a4248d0ee882aa5a48a1d74ca0162032c5a7d65e;hpb=65e85a0acdb22bd25386f4fe9cde50c66339a496 diff --git a/fuse/main.c b/fuse/main.c index fe5666b..a813427 100644 --- a/fuse/main.c +++ b/fuse/main.c @@ -37,7 +37,7 @@ #error FUSE 2.6 or later is required #endif -const char* default_options = "allow_other,blkdev"; +const char* default_options = "ro_fallback,allow_other,blkdev"; struct exfat ef; @@ -426,6 +426,16 @@ int main(int argc, char* argv[]) return 1; } + if (ef.ro_fallback) + { + mount_options = add_option(mount_options, "ro", NULL); + if (mount_options == NULL) + { + exfat_unmount(&ef); + return 1; + } + } + mount_options = add_fuse_options(mount_options, spec); if (mount_options == NULL) {