set help package as install requires
This commit is contained in:
parent
85b05a580d
commit
da06a586b7
60
0004-add-device-check-in-ismount-process.patch
Normal file
60
0004-add-device-check-in-ismount-process.patch
Normal file
@ -0,0 +1,60 @@
|
||||
From 72e7f067a0d7671b372c23ee727b39b5b24f93da Mon Sep 17 00:00:00 2001
|
||||
From: guiyao <guiyao@huawei.com>
|
||||
Date: Wed, 15 Apr 2020 20:13:26 +0000
|
||||
Subject: [PATCH] add device check in ismount process
|
||||
|
||||
Signed-off-by: guiyao <guiyao@huawei.com>
|
||||
Signed-off-by: Shijie Luo <luoshijie1@huawei.com>
|
||||
---
|
||||
lib/ext2fs/ismounted.c | 16 ++++++++++------
|
||||
1 file changed, 10 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/lib/ext2fs/ismounted.c b/lib/ext2fs/ismounted.c
|
||||
index 46d330d..2add4c0 100644
|
||||
--- a/lib/ext2fs/ismounted.c
|
||||
+++ b/lib/ext2fs/ismounted.c
|
||||
@@ -98,6 +98,7 @@ static errcode_t check_mntent_file(const char *mtab_file, const char *file,
|
||||
{
|
||||
struct mntent *mnt;
|
||||
struct stat st_buf;
|
||||
+ struct stat dir_st_buf;
|
||||
errcode_t retval = 0;
|
||||
dev_t file_dev=0, file_rdev=0;
|
||||
ino_t file_ino=0;
|
||||
@@ -128,24 +129,27 @@ static errcode_t check_mntent_file(const char *mtab_file, const char *file,
|
||||
while ((mnt = getmntent (f)) != NULL) {
|
||||
if (mnt->mnt_fsname[0] != '/')
|
||||
continue;
|
||||
- if (stat(mnt->mnt_dir, &st_buf) != 0)
|
||||
+ if (stat(mnt->mnt_dir, &dir_st_buf) != 0)
|
||||
continue;
|
||||
if (strcmp(file, mnt->mnt_fsname) == 0) {
|
||||
- if (file_rdev && (file_rdev != st_buf.st_dev)) {
|
||||
+ if (file_rdev && (file_rdev == dir_st_buf.st_dev)) {
|
||||
#ifdef DEBUG
|
||||
printf("Bogus entry in %s! "
|
||||
"(%s does not exist)\n",
|
||||
mtab_file, mnt->mnt_dir);
|
||||
#endif /* DEBUG */
|
||||
- continue;
|
||||
+ break;
|
||||
}
|
||||
- break;
|
||||
+ continue;
|
||||
}
|
||||
if (stat(mnt->mnt_fsname, &st_buf) == 0) {
|
||||
if (ext2fsP_is_disk_device(st_buf.st_mode)) {
|
||||
#ifndef __GNU__
|
||||
- if (file_rdev && (file_rdev == st_buf.st_rdev))
|
||||
- break;
|
||||
+ if (file_rdev && (file_rdev == st_buf.st_rdev)){
|
||||
+ if (file_rdev == dir_st_buf.st_dev) {
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
if (check_loop_mounted(mnt->mnt_fsname,
|
||||
st_buf.st_rdev, file_dev,
|
||||
file_ino) == 1)
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
Name: e2fsprogs
|
||||
Version: 1.45.6
|
||||
Release: 2
|
||||
Release: 3
|
||||
Summary: Second extended file system management tools
|
||||
License: GPLv2 and LGPLv2 and MIT
|
||||
URL: http://e2fsprogs.sourceforge.net/
|
||||
@ -9,9 +9,11 @@ Source0: https://www.kernel.org/pub/linux/kernel/people/tytso/%{name}/v%{
|
||||
Patch1: 0001-e2fsprogs-set-hugefile-from-4T-to-1T-in-hugefile-tes.patch
|
||||
Patch2: 0002-e2fsck-fix-off-by-one-check-when-validating-depth-of.patch
|
||||
Patch3: 0003-mke2fs-fix-up-check-for-hardlinks-always-false-if-in.patch
|
||||
Patch4: 0004-add-device-check-in-ismount-process.patch
|
||||
|
||||
BuildRequires: gcc git pkgconfig texinfo
|
||||
BuildRequires: fuse-devel libblkid-devel libuuid-devel
|
||||
Recommends: %{name}-help = %{version}-%{release}
|
||||
|
||||
Provides: e2fsprogs-libs%{?_isa} e2fsprogs-libs
|
||||
Obsoletes: e2fsprogs-libs
|
||||
@ -128,6 +130,9 @@ exit 0
|
||||
%{_mandir}/man8/*
|
||||
|
||||
%changelog
|
||||
* Wed Dec 16 2020 yanglongkang <yanglongkang@huawei.com> - 1.45.6-3
|
||||
- Set help package as install require
|
||||
|
||||
* Fri Oct 30 2020 Zhiqiang Liu <lzhq28@mail.ustc.edu.cn> - 1.45.6-2
|
||||
- backport upstream patches-epoch2 to fix some problems
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user