fix
authorMiklos Szeredi <miklos@szeredi.hu>
Thu, 16 Sep 2004 08:43:24 +0000 (08:43 +0000)
committerMiklos Szeredi <miklos@szeredi.hu>
Thu, 16 Sep 2004 08:43:24 +0000 (08:43 +0000)
lib/helper.c

index 70c4bd866e778db3822d7253201b8afeec6b8ad6..b9e81503d4eae100ff1b03752885a39ffa5aeb8c 100644 (file)
@@ -93,6 +93,7 @@ static int fuse_do(int fuse_fd, const char *opts, int multithreaded,
                       int background, const struct fuse_operations *op)
 {
     int pid;
+    int res;
 
     fuse = fuse_new(fuse_fd, opts, op);
     if (fuse == NULL)
@@ -110,12 +111,15 @@ static int fuse_do(int fuse_fd, const char *opts, int multithreaded,
     set_signal_handlers();
 
     if (multithreaded)
-        fuse_loop_mt(fuse);
+        res = fuse_loop_mt(fuse);
     else
-        fuse_loop(fuse);
+        res = fuse_loop(fuse);
     
     fuse_destroy(fuse);
 
+    if (res == -1)
+        return 1;
+
     return 0;
 }