[gparted/ataraid: 3/12] Detect busy status of mdadm started ATARAID members (#75)
- From: Mike Fleetwood <mfleetwo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gparted/ataraid: 3/12] Detect busy status of mdadm started ATARAID members (#75)
- Date: Mon, 2 Dec 2019 09:29:49 +0000 (UTC)
commit 8be2ed629b33c793f028844ef576d7c7bb96b58f
Author: Mike Fleetwood <mike fleetwood googlemail com>
Date: Sun Nov 17 19:16:41 2019 +0000
Detect busy status of mdadm started ATARAID members (#75)
This stops GParted allowing overwrite operations (such as create
partition table or format with a whole device file system) being
performed on an ATARAID member while the array is actively using the
member.
Closes #75 - Errors with GPT on RAID 0 ATARAID array
src/Dialog_Partition_Info.cc | 4 +++-
src/GParted_Core.cc | 5 +++--
2 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/src/Dialog_Partition_Info.cc b/src/Dialog_Partition_Info.cc
index 68e831d7..b98a7f3d 100644
--- a/src/Dialog_Partition_Info.cc
+++ b/src/Dialog_Partition_Info.cc
@@ -327,6 +327,7 @@ void Dialog_Partition_Info::Display_Info()
}
else if ( filesystem_ptn.filesystem == FS_LINUX_SWAP ||
filesystem_ptn.filesystem == FS_LINUX_SWRAID ||
+ filesystem_ptn.filesystem == FS_ATARAID ||
filesystem_ptn.filesystem == FS_LVM2_PV )
{
/* TO TRANSLATORS: Active
@@ -360,7 +361,8 @@ void Dialog_Partition_Info::Display_Info()
str_temp = _("Not busy (There are no mounted logical partitions)") ;
}
else if ( filesystem_ptn.filesystem == FS_LINUX_SWAP ||
- filesystem_ptn.filesystem == FS_LINUX_SWRAID )
+ filesystem_ptn.filesystem == FS_LINUX_SWRAID ||
+ filesystem_ptn.filesystem == FS_ATARAID )
{
/* TO TRANSLATORS: Not active
* means that this linux swap or linux software raid partition
diff --git a/src/GParted_Core.cc b/src/GParted_Core.cc
index f5530080..6317e32c 100644
--- a/src/GParted_Core.cc
+++ b/src/GParted_Core.cc
@@ -1522,8 +1522,9 @@ bool GParted_Core::is_busy( FSType fstype, const Glib::ustring & path )
// unknown file system is mounted
busy = Mount_Info::is_dev_mounted( path );
- //Custom checks for recognised but other not-supported file system types
- busy |= ( fstype == FS_LINUX_SWRAID && SWRaid_Info::is_member_active( path ) );
+ // Custom checks for recognised but other not-supported file system types.
+ busy |= (fstype == FS_LINUX_SWRAID && SWRaid_Info::is_member_active(path));
+ busy |= (fstype == FS_ATARAID && SWRaid_Info::is_member_active(path));
}
return busy ;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]