neil / rpms / udisks2

Forked from rpms/udisks2 a year ago
Clone
20ccde
From 39d13907f712269bb9debd0fd8a0852347c98136 Mon Sep 17 00:00:00 2001
20ccde
From: Tomas Bzatek <tbzatek@redhat.com>
20ccde
Date: Fri, 26 Jun 2020 17:55:53 +0200
20ccde
Subject: [PATCH 2/8] lvm2: Always flush interface property changes
20ccde
20ccde
---
20ccde
 modules/lvm2/udiskslinuxlogicalvolume.c     | 3 +++
20ccde
 modules/lvm2/udiskslinuxphysicalvolume.c    | 2 ++
20ccde
 modules/lvm2/udiskslinuxvdovolume.c         | 2 ++
20ccde
 modules/lvm2/udiskslinuxvolumegroup.c       | 3 +++
20ccde
 modules/lvm2/udiskslinuxvolumegroupobject.c | 3 +++
20ccde
 5 files changed, 13 insertions(+)
20ccde
20ccde
diff --git a/modules/lvm2/udiskslinuxlogicalvolume.c b/modules/lvm2/udiskslinuxlogicalvolume.c
20ccde
index 373cee2e..c0f074d8 100644
20ccde
--- a/modules/lvm2/udiskslinuxlogicalvolume.c
20ccde
+++ b/modules/lvm2/udiskslinuxlogicalvolume.c
20ccde
@@ -229,6 +229,8 @@ udisks_linux_logical_volume_update (UDisksLinuxLogicalVolume     *logical_volume
20ccde
       logical_volume->needs_udev_hack = FALSE;
20ccde
       g_free (dev_file);
20ccde
     }
20ccde
+
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface));
20ccde
 }
20ccde
 
20ccde
 void
20ccde
@@ -248,6 +250,7 @@ udisks_linux_logical_volume_update_etctabs (UDisksLinuxLogicalVolume     *logica
20ccde
   udisks_logical_volume_set_child_configuration (iface,
20ccde
                                                  udisks_linux_find_child_configuration (daemon,
20ccde
                                                                                         uuid));
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface));
20ccde
 }
20ccde
 
20ccde
 /* ---------------------------------------------------------------------------------------------------- */
20ccde
diff --git a/modules/lvm2/udiskslinuxphysicalvolume.c b/modules/lvm2/udiskslinuxphysicalvolume.c
20ccde
index 27043030..36e7c322 100644
20ccde
--- a/modules/lvm2/udiskslinuxphysicalvolume.c
20ccde
+++ b/modules/lvm2/udiskslinuxphysicalvolume.c
20ccde
@@ -143,6 +143,8 @@ udisks_linux_physical_volume_update   (UDisksLinuxPhysicalVolume    *physical_vo
20ccde
       udisks_physical_volume_set_size (iface, pv_info->pv_size);
20ccde
       udisks_physical_volume_set_free_size (iface, pv_info->pv_free);
20ccde
     }
20ccde
+
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface));
20ccde
 }
20ccde
 
20ccde
 /* ---------------------------------------------------------------------------------------------------- */
20ccde
diff --git a/modules/lvm2/udiskslinuxvdovolume.c b/modules/lvm2/udiskslinuxvdovolume.c
20ccde
index 317eddc2..430e2814 100644
20ccde
--- a/modules/lvm2/udiskslinuxvdovolume.c
20ccde
+++ b/modules/lvm2/udiskslinuxvdovolume.c
20ccde
@@ -177,6 +177,8 @@ udisks_linux_vdo_volume_update (UDisksLinuxVDOVolume         *vdo_volume,
20ccde
 
20ccde
   udisks_vdo_volume_set_compression (iface, vdo_info->compression);
20ccde
   udisks_vdo_volume_set_deduplication (iface, vdo_info->deduplication);
20ccde
+
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface));
20ccde
 }
20ccde
 
20ccde
 /* ---------------------------------------------------------------------------------------------------- */
20ccde
diff --git a/modules/lvm2/udiskslinuxvolumegroup.c b/modules/lvm2/udiskslinuxvolumegroup.c
20ccde
index aad2193e..3fbf6f02 100644
20ccde
--- a/modules/lvm2/udiskslinuxvolumegroup.c
20ccde
+++ b/modules/lvm2/udiskslinuxvolumegroup.c
20ccde
@@ -136,11 +136,14 @@ udisks_linux_volume_group_update (UDisksLinuxVolumeGroup *volume_group,
20ccde
                                   gboolean               *needs_polling_ret)
20ccde
 {
20ccde
   UDisksVolumeGroup *iface = UDISKS_VOLUME_GROUP (volume_group);
20ccde
+
20ccde
   udisks_volume_group_set_name (iface, vg_info->name);
20ccde
   udisks_volume_group_set_uuid (iface, vg_info->uuid);
20ccde
   udisks_volume_group_set_size (iface, vg_info->size);
20ccde
   udisks_volume_group_set_free_size (iface, vg_info->free);
20ccde
   udisks_volume_group_set_extent_size (iface, vg_info->extent_size);
20ccde
+
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface));
20ccde
 }
20ccde
 
20ccde
 /* ---------------------------------------------------------------------------------------------------- */
20ccde
diff --git a/modules/lvm2/udiskslinuxvolumegroupobject.c b/modules/lvm2/udiskslinuxvolumegroupobject.c
20ccde
index 50e9c640..e3bc8dfc 100644
20ccde
--- a/modules/lvm2/udiskslinuxvolumegroupobject.c
20ccde
+++ b/modules/lvm2/udiskslinuxvolumegroupobject.c
20ccde
@@ -442,6 +442,7 @@ block_object_update_lvm_iface (UDisksLinuxBlockObject *object,
20ccde
 
20ccde
   udisks_linux_block_lvm2_update (UDISKS_LINUX_BLOCK_LVM2 (iface_block_lvm2), object);
20ccde
   udisks_block_lvm2_set_logical_volume (iface_block_lvm2, lv_obj_path);
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (iface_block_lvm2));
20ccde
 }
20ccde
 
20ccde
 static void
20ccde
@@ -456,6 +457,7 @@ lv_object_update_block_path (UDisksLinuxBlockObject       *block_object,
20ccde
     {
20ccde
       block_objpath = g_dbus_object_get_object_path (G_DBUS_OBJECT (block_object));
20ccde
       udisks_logical_volume_set_block_device (UDISKS_LOGICAL_VOLUME (lv), block_objpath);
20ccde
+      g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (lv));
20ccde
     }
20ccde
 }
20ccde
 
20ccde
@@ -695,6 +697,7 @@ update_vg (GObject      *source_obj,
20ccde
   bd_lvm_vgdata_free (vg_info);
20ccde
   lv_list_free (lvs);
20ccde
 
20ccde
+  g_dbus_interface_skeleton_flush (G_DBUS_INTERFACE_SKELETON (object->iface_volume_group));
20ccde
   g_object_unref (object);
20ccde
 }
20ccde
 
20ccde
-- 
20ccde
2.26.2
20ccde