mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-22 07:03:38 +00:00
fish: Don't fail if some mountpoints in /etc/fstab are bogus (RHBZ#668574).
Fix guestfish (and other C tools) so that they ignore errors
when /etc/fstab contains bogus entries.
Update the documentation for inspect-get-mountpoints to emphasize
that callers must be aware of this when mounting the returned
values.
Add a regression test.
Update the example code ("inspect_vm") to reflect the way this
API ought to be called.
For more detail see:
https://bugzilla.redhat.com/show_bug.cgi?id=668574
This commit is contained in:
@@ -44,7 +44,10 @@ for root in roots:
|
||||
return -1
|
||||
mps.sort (compare)
|
||||
for mp_dev in mps:
|
||||
g.mount_ro (mp_dev[1], mp_dev[0])
|
||||
try:
|
||||
g.mount_ro (mp_dev[1], mp_dev[0])
|
||||
except RuntimeError as msg:
|
||||
print "%s (ignored)" % msg
|
||||
|
||||
# If /etc/issue.net file exists, print up to 3 lines.
|
||||
filename = "/etc/issue.net"
|
||||
|
||||
Reference in New Issue
Block a user