From ea26fcb4fafad20b7300473b3c19c45856bf2db0 Mon Sep 17 00:00:00 2001 From: Rogier Goossens Date: Sun, 1 Apr 2012 10:49:19 +0200 Subject: [PATCH] Fix for FS size & flags becoming unknown after change UUID AFAICS, there is no reason to manually copy all partition fields, or to manually initialize the copy of the new partition object. So now the partition object is simply copied using assignment. --- src/Win_GParted.cc | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/src/Win_GParted.cc b/src/Win_GParted.cc index 06b38b9d..c2302827 100644 --- a/src/Win_GParted.cc +++ b/src/Win_GParted.cc @@ -2396,19 +2396,7 @@ void Win_GParted::activate_change_uuid() } //Make a duplicate of the selected partition (used in UNDO) - Partition part_temp ; - part_temp .Set( devices[ current_device ] .get_path(), - selected_partition .get_path(), - selected_partition .partition_number, - selected_partition .type, - selected_partition .filesystem, - selected_partition .sector_start, - selected_partition .sector_end, - devices[ current_device ] .sector_size, - selected_partition .inside_extended, - false ) ; - - part_temp .label = selected_partition .label ; + Partition part_temp = selected_partition ; if ( part_temp .filesystem == GParted::FS_NTFS ) //Explicitly ask for half, so that the user will be aware of it