[udisks2] Add upstream patch to fix issue with rootfs being on a bound mount

Peter Robinson pbrobinson at fedoraproject.org
Tue May 22 11:12:03 UTC 2012


commit d4d8ff7c236182776fea71af471eade5e9e7d952
Author: Peter Robinson <pbrobinson at gmail.com>
Date:   Tue May 22 12:11:58 2012 +0100

    Add upstream patch to fix issue with rootfs being on a bound mount

 udisks2-root-bound-mount-fix.patch |   35 +++++++++++++++++++++++++++++++++++
 udisks2.spec                       |    9 ++++++++-
 2 files changed, 43 insertions(+), 1 deletions(-)
---
diff --git a/udisks2-root-bound-mount-fix.patch b/udisks2-root-bound-mount-fix.patch
new file mode 100644
index 0000000..53d711b
--- /dev/null
+++ b/udisks2-root-bound-mount-fix.patch
@@ -0,0 +1,35 @@
+From e0b8ffe3099735fefd64973e6575c67ac0759be2 Mon Sep 17 00:00:00 2001
+From: David Zeuthen <davidz at redhat.com>
+Date: Tue, 15 May 2012 14:17:22 +0000
+Subject: Bug 49842 – Unhandled rootfs on bind mount
+
+Don't ignore a mount just because if a subtree of the filesystem is
+mounted. Because if we do this, we may wrongly conclude the device is
+not mounted at all, which then means that it's visible in the desktop
+UI and subject to automounting.
+
+In the future, we may want a "a(ss) MountPointsFull" property that in
+addition to the mount point also contains the subtree that is mounted
+at said mountpoint.
+
+https://bugs.freedesktop.org/show_bug.cgi?id=49842
+
+Signed-off-by: David Zeuthen <davidz at redhat.com>
+---
+diff --git a/src/udisksmountmonitor.c b/src/udisksmountmonitor.c
+index 43adaa5..36e1476 100644
+--- a/src/udisksmountmonitor.c
++++ b/src/udisksmountmonitor.c
+@@ -433,10 +433,6 @@ udisks_mount_monitor_get_mountinfo (UDisksMountMonitor  *monitor,
+           continue;
+         }
+ 
+-      /* ignore mounts where only a subtree of a filesystem is mounted */
+-      if (g_strcmp0 (encoded_root, "/") != 0)
+-        continue;
+-
+       /* Temporary work-around for btrfs, see
+        *
+        *  https://bugzilla.redhat.com/show_bug.cgi?id=495152#c31
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/udisks2.spec b/udisks2.spec
index 6a8deea..34a875b 100644
--- a/udisks2.spec
+++ b/udisks2.spec
@@ -8,11 +8,14 @@
 Summary: Disk Manager
 Name: udisks2
 Version: 1.97.0
-Release: 2%{?dist}
+Release: 3%{?dist}
 License: GPLv2+
 Group: System Environment/Libraries
 URL: http://www.freedesktop.org/wiki/Software/udisks
 Source0: http://udisks.freedesktop.org/releases/udisks-%{version}.tar.bz2
+# https://bugs.freedesktop.org/show_bug.cgi?id=49842
+Patch0: udisks2-root-bound-mount-fix.patch
+
 BuildRequires: glib2-devel >= %{glib2_version}
 BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version}
 BuildRequires: polkit-devel >= %{polkit_version}
@@ -86,6 +89,7 @@ daemon. This package is for the udisks 2.x series.
 
 %prep
 %setup -q -n udisks-%{version}
+%patch0 -p1 -b .root-bound-mount-fix
 
 %build
 %configure --enable-gtk-doc
@@ -143,6 +147,9 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/*.a
 
 # Note: please don't forget the %{?dist} in the changelog. Thanks
 %changelog
+* Tue May 22 2012 Peter Robinson <pbrobinson at fedoraproject.org> - 1.97.0-3
+- Add upstream patch to fix issue with rootfs being on a bound mount
+
 * Fri May 18 2012 Matthias Clasen <mclasen at redhat.com> - 1.97.0-2%{?dist}
 - Add a Requires for eject (#810882)
 


More information about the scm-commits mailing list