backport libgfs2: Fix gfs[2]_log_header metadata description

This commit is contained in:
liyuan 2023-10-20 08:15:25 +08:00
parent d7ac5d7226
commit 560ef48299
2 changed files with 41 additions and 1 deletions

View File

@ -0,0 +1,36 @@
From 2f8edd6e164e378773a3195a2adbfe874b288050 Mon Sep 17 00:00:00 2001
From: Andreas Gruenbacher <agruenba@redhat.com>
Date: Mon, 25 Mar 2019 23:11:04 +0000
Subject: [PATCH] libgfs2: Fix gfs[2]_log_header metadata description
We want to use the lgfs2_lh_flags array for decoding the lh_flags field
in gfs2_log_header, not gfs_log_header.
---
gfs2/libgfs2/meta.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gfs2/libgfs2/meta.c b/gfs2/libgfs2/meta.c
index 486e0ea6..1da74146 100644
--- a/gfs2/libgfs2/meta.c
+++ b/gfs2/libgfs2/meta.c
@@ -388,7 +388,7 @@ MH(jd_header)
static const struct lgfs2_metafield gfs2_log_header_fields[] = {
MH(lh_header)
F(lh_sequence)
-F(lh_flags)
+F(lh_flags, .flags = LGFS2_MFF_MASK, .symtab = lgfs2_lh_flags, .nsyms = ARRAY_SIZE(lgfs2_lh_flags))
F(lh_tail)
F(lh_blkno)
F(lh_hash, .flags = LGFS2_MFF_CHECK)
@@ -411,7 +411,7 @@ F(lh_local_dinodes, .flags = LGFS2_MFF_FSBLOCKS)
static const struct lgfs2_metafield gfs_log_header_fields[] = {
MH(lh_header)
-F(lh_flags, .flags = LGFS2_MFF_MASK, .symtab = lgfs2_lh_flags, .nsyms = ARRAY_SIZE(lgfs2_lh_flags))
+F(lh_flags)
RF(lh_pad)
F(lh_first)
F(lh_sequence)
--
2.33.0

View File

@ -1,6 +1,6 @@
Name: gfs2-utils
Version: 3.2.0
Release: 6
Release: 7
Summary: Global Filesystem Utilities
License: GPLv2+ and LGPLv2+
@ -8,6 +8,7 @@ URL: https://pagure.io/gfs2-utils
Source0: https://releases.pagure.org/gfs2-utils/gfs2-utils-%{version}.tar.gz
Patch0001: 0001-libgfs2-Fix-pointer-cast-byte-order-issue.patch
Patch0002: 0002-libgfs2-Fix-gfs-2-_log_header-metadata-description.patch
BuildRequires: ncurses-devel kernel-headers automake libtool zlib-devel gettext-devel
BuildRequires: bison flex libblkid-devel libuuid-devel check-devel
@ -53,6 +54,9 @@ make -C gfs2 install DESTDIR=%{buildroot}
%exclude %{_mandir}/man8/gfs2_lockcapture.8.gz
%changelog
* Thu Oct 26 2023 liyuanyuan <liyuanyuan@xfusion.com> - 3.2.0-7
- libgfs2: Fix gfs[2]_log_header metadata description
* Thu Oct 19 2023 liyuanyuan <liyuanyuan@xfusion.com> - 3.2.0-6
- libgfs2: Fix pointer cast byte order issue