diff options
author | Lennart Poettering <lennart@poettering.net> | 2016-12-15 17:38:11 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2016-12-21 19:09:30 +0100 |
commit | e0f9e7bd03eebeb8fdfce7f766c4e254e3586dc8 (patch) | |
tree | 05a9df559074b9194fe15b5b6f08dfc0c2af636a /src/machine/image-dbus.c | |
parent | dissect: return the GPT partition UUID, too (diff) | |
download | systemd-e0f9e7bd03eebeb8fdfce7f766c4e254e3586dc8.tar.xz systemd-e0f9e7bd03eebeb8fdfce7f766c4e254e3586dc8.zip |
dissect: make using a generic partition as root partition optional
In preparation for reusing the image dissector in the GPT auto-discovery
logic, only optionally fail the dissection when we can't identify a root
partition.
In the GPT auto-discovery we are completely fine with any kind of root,
given that we run when it is already mounted and all we do is find some
additional auxiliary partitions on the same disk.
Diffstat (limited to 'src/machine/image-dbus.c')
-rw-r--r-- | src/machine/image-dbus.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/machine/image-dbus.c b/src/machine/image-dbus.c index 2b168b267b..1891f07586 100644 --- a/src/machine/image-dbus.c +++ b/src/machine/image-dbus.c @@ -336,7 +336,7 @@ static int raw_image_get_os_release(Image *image, char ***ret, sd_bus_error *err if (r < 0) return sd_bus_error_set_errnof(error, r, "Failed to set up loop block device for %s: %m", image->path); - r = dissect_image(d->fd, NULL, 0, 0, &m); + r = dissect_image(d->fd, NULL, 0, DISSECT_IMAGE_REQUIRE_ROOT, &m); if (r == -ENOPKG) return sd_bus_error_set_errnof(error, r, "Disk image %s not understood: %m", image->path); if (r < 0) |