git.annexia.org
/
libguestfs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fish: mount can be used instead of mount-options with libguestfs >= 1.14
[libguestfs.git]
/
fish
/
inspect.c
diff --git
a/fish/inspect.c
b/fish/inspect.c
index
7d4401e
..
f93367b
100644
(file)
--- a/
fish/inspect.c
+++ b/
fish/inspect.c
@@
-154,8
+154,14
@@
inspect_mount_root (const char *root)
r = guestfs_mount_options (g, "", mountpoints[i+1], mountpoints[i]);
else
r = guestfs_mount_ro (g, mountpoints[i+1], mountpoints[i]);
r = guestfs_mount_options (g, "", mountpoints[i+1], mountpoints[i]);
else
r = guestfs_mount_ro (g, mountpoints[i+1], mountpoints[i]);
- if (r == -1)
+ if (r == -1) {
+ /* If the "/" filesystem could not be mounted, give up, else
+ * just count the errors and print a warning.
+ */
+ if (STREQ (mountpoints[i], "/"))
+ exit (EXIT_FAILURE);
mount_errors++;
mount_errors++;
+ }
}
free_strings (mountpoints);
}
free_strings (mountpoints);