diff --git a/0004-Fix-GError-use-after-free.patch b/0004-Fix-GError-use-after-free.patch new file mode 100644 index 0000000000000000000000000000000000000000..46f958819d2c8df2767bdb1e81d184e0e73b297c --- /dev/null +++ b/0004-Fix-GError-use-after-free.patch @@ -0,0 +1,28 @@ +From 2a28ac8ff924ca673800d3f2b69c12c3e79327bc Mon Sep 17 00:00:00 2001 +From: Tomas Bzatek +Date: Mon, 10 Jun 2024 16:54:13 +0200 +Subject: [PATCH] udiskslinuxloop: Fix GError use-after-free + +https://bugzilla.redhat.com/show_bug.cgi?id=2290953 + +--- + src/udiskslinuxloop.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/udiskslinuxloop.c b/src/udiskslinuxloop.c +index 5f162f1..500df6e 100644 +--- a/src/udiskslinuxloop.c ++++ b/src/udiskslinuxloop.c +@@ -263,8 +263,8 @@ handle_delete (UDisksLoop *loop, + if (!bd_loop_teardown (device_file, &error)) + { + g_prefix_error (&error, "Error deleting '%s': ", device_file); +- g_dbus_method_invocation_take_error (invocation, error); + udisks_simple_job_complete (UDISKS_SIMPLE_JOB (job), FALSE, error->message); ++ g_dbus_method_invocation_take_error (invocation, error); + goto out; + } + +-- +2.27.0 + diff --git a/udisks2.spec b/udisks2.spec index bbf469c456b1872b2b1d49a2ad62892726304ee2..71966ee47b9d32bddcaed2c1dee53d83ad6d29d1 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -19,7 +19,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.10.1 -Release: 4 +Release: 5 License: GPL-2.0+ and LGPL-2.0+ Group: System Environment/Libraries URL: https://github.com/storaged-project/udisks @@ -28,6 +28,7 @@ Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{v Patch0001: 0001-mdraid-Expose-consistency_policy-sysfs-value.patch Patch0002: 0002-udiskslinuxmanager-use-dbus-interface-after-free.patch Patch0003: 0003-udiskslinuxblock-Fix-leaking-string.patch +Patch0004: 0004-Fix-GError-use-after-free.patch BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} @@ -318,6 +319,9 @@ fi %changelog +* Wed Oct 16 2024 yanshuai - 2.10.1-5 +- udiskslinuxloop: Fix GError use-after-free + * Tue Aug 13 2024 cenhuilin - 2.10.1-4 - udiskslinuxblock: Fix leaking string