diff options
author | Gilles Moris <gilles.moris@free.fr> | 2019-05-15 07:07:21 +0200 |
---|---|---|
committer | Gilles Moris <gilles.moris@free.fr> | 2019-05-15 07:07:21 +0200 |
commit | 94b1490b7b906b90e743512edd305302ed96ce0f (patch) | |
tree | 94f544b4d84702270a7b7dad7f2622a954479da9 /gptpart.cc | |
parent | faaaa2618f965d12fc47837aa026bd123f680098 (diff) | |
download | sgdisk-94b1490b7b906b90e743512edd305302ed96ce0f.tar.gz |
Create a constant unusedPartType object instead of recreating it each time
Diffstat (limited to 'gptpart.cc')
-rw-r--r-- | gptpart.cc | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -434,7 +434,7 @@ void GPTPart::ReversePartBytes(void) { void GPTPart::ChangeType(void) { string line; int changeName; - PartType tempType = (GUIDData) "00000000-0000-0000-0000-000000000000"; + PartType tempType = PartType::unusedPartType; #ifdef USE_UTF16 changeName = (GetDescription() == GetUTypeName()); @@ -454,7 +454,7 @@ void GPTPart::ChangeType(void) { else tempType = line; } // if/else - } while (tempType == (GUIDData) "00000000-0000-0000-0000-000000000000"); + } while (tempType == PartType::unusedPartType); partitionType = tempType; cout << "Changed type of partition to '" << partitionType.TypeName() << "'\n"; if (changeName) { |