代码拉取完成,页面将自动刷新
From 990b4136608ad1ae69e9727ccb16b9ecf88644e5 Mon Sep 17 00:00:00 2001
From: Tomas Bzatek <tbzatek@redhat.com>
Date: Mon, 20 Nov 2023 17:49:46 +0100
Subject: [PATCH] lvm-dbus: Fix leaking error
---
src/plugins/lvm-dbus.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/src/plugins/lvm-dbus.c b/src/plugins/lvm-dbus.c
index e822bd6..e1a9079 100644
--- a/src/plugins/lvm-dbus.c
+++ b/src/plugins/lvm-dbus.c
@@ -362,10 +362,14 @@ void bd_lvm_close (void) {
/* the check() call should create the DBus connection for us, but let's not
completely rely on it */
- if (!g_dbus_connection_flush_sync (bus, NULL, &error))
+ if (!g_dbus_connection_flush_sync (bus, NULL, &error)) {
bd_utils_log_format (BD_UTILS_LOG_CRIT, "Failed to flush DBus connection: %s", error->message);
- if (!g_dbus_connection_close_sync (bus, NULL, &error))
+ g_clear_error (&error);
+ }
+ if (!g_dbus_connection_close_sync (bus, NULL, &error)) {
bd_utils_log_format (BD_UTILS_LOG_CRIT, "Failed to close DBus connection: %s", error->message);
+ g_clear_error (&error);
+ }
dm_log_with_errno_init (NULL);
dm_log_init_verbose (0);
--
2.27.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。